<template>
  <div class="pubBig standard Bedinformation1">
    <div class="h0">
      <p class="lt"></p>
    </div>
    <div class="dRightMain">
      <el-tabs
        v-model="getHZListObj.topstatus"
        @tab-click="handleClick"
      >
        <el-tab-pane
          label="我的申请"
          name="1"
        >
          <div
            style="height: 80%"
            class="cardP"
          >
            <el-card class="box-card">
              <div
                slot="header"
                class="clearfix"
              >
                <span>会诊信息</span>
                <el-button
                  style="float: right; padding: 3px 0"
                  type="text"
                  v-if="false"
                >操作按钮
                </el-button>
              </div>
              <div>
                <el-row>
                  <el-col :span="6">
                    <div class="grid-content bg-purple div_P">
                      <div class=" form-group ">
                        <p>
                          <template>
                            <el-radio
                              v-model="getHZListObj.secstatus"
                              @change="getHZList"
                              label="1"
                            >待办会诊
                            </el-radio>
                            <el-radio
                              v-model="getHZListObj.secstatus"
                              @change="getHZList"
                              label="2"
                            >已办会诊
                            </el-radio>
                          </template>
                        </p>
                      </div>
                    </div>
                  </el-col>
                  <el-col :span="12">
                    <div class="grid-content bg-purple-light div_P">
                      <div class="form-group">
                        <p class="selectTime">
                          <label>会诊日期:</label>
                          <el-date-picker
                            style="width:168px;height:32px"
                            type="date"
                            v-model="getHZListObj.mbdate"
                            value-format="yyyy-MM-dd "
                            @change="getHZList"
                            placeholder="选择日期"
                          >
                          </el-date-picker>
                          -
                          <el-date-picker
                            style="width:168px;height:32px"
                            type="date"
                            v-model="getHZListObj.medate"
                            @change="getHZList"
                            value-format="yyyy-MM-dd "
                            placeholder="选择日期"
                          >
                          </el-date-picker>
                        </p>
                      </div>
                    </div>
                  </el-col>
                  <el-col :span="6">
                    <div class="grid-content bg-purple div_P">
                      <div class="form-group">
                        <p>
                          <label>申请医院:</label>
                          <select
                            class="form-control"
                            v-model="getHZListObj.hospname"
                            placeholder="请选择"
                            @change="getHZList"
                          >
                            <option
                              v-for="(item,index) in zzjgList"
                              :label="item.HospitalName"
                              :value="item.HospitalName"
                              :key="index"
                            ></option>
                          </select>
                        </p>
                      </div>
                    </div>
                  </el-col>

                </el-row>
              </div>
            </el-card>
            <el-table
              :data="huizhenList"
              height="326"
              border
              style="width: 100%"
            >
              <el-table-column
                fixed
                prop="Name"
                label="患者姓名"
                width="120"
              >
              </el-table-column>
              <el-table-column
                prop="Id"
                label="会诊编号"
                width="120"
              >
              </el-table-column>

              <el-table-column
                prop="SubscribeTime"
                label="申请时间"
                width="120"
              >
              </el-table-column>
              <el-table-column
                prop="Request"
                label="申请方"
              >
              </el-table-column>

              <el-table-column
                prop="Joins"
                label="参与方"
              >
              </el-table-column>
              <el-table-column
                prop="StatusName"
                label="状态"
              >
              </el-table-column>
              <el-table-column
                fixed="right"
                label="操作"
                width="160"
              >
                <template slot-scope="scope">
                  <el-button
                    @click="handleClickInforItem(scope.row)"
                    type="text"
                    size="small"
                  >查看详情
                  </el-button>
                </template>
              </el-table-column>
            </el-table>
            <el-pagination
              background
              layout="prev, pager, next"
              :page-size="10"
              @current-change="handleCurrentChange"
              :total="total"
            >
            </el-pagination>
          </div>
        </el-tab-pane>
        <el-tab-pane
          label="我的会诊"
          name="2"
        >
          <div
            style="height: 80%"
            class="cardP"
          >
            <el-card class="box-card">
              <div
                slot="header"
                class="clearfix"
              >
                <span>会诊信息</span>
                <el-button
                  style="float: right; padding: 3px 0"
                  type="text"
                  v-if="false"
                >操作按钮
                </el-button>
              </div>
              <div>
                <el-row>
                  <el-col :span="6">
                    <div class="grid-content bg-purple div_P">
                      <div class=" form-group ">
                        <p>
                          <template>
                            <el-radio
                              v-model="getHZListObj.secstatus"
                              @change="getHZList"
                              label="1"
                            >待办会诊
                            </el-radio>
                            <el-radio
                              v-model="getHZListObj.secstatus"
                              @change="getHZList"
                              label="2"
                            >已办会诊
                            </el-radio>
                          </template>
                        </p>
                      </div>
                    </div>
                  </el-col>
                  <el-col :span="12">
                    <div class="grid-content bg-purple-light div_P">
                      <div class="form-group">
                        <p class="selectTime">
                          <label>会诊日期:</label>
                          <el-date-picker
                            style="width:168px;height:32px"
                            type="date"
                            v-model="getHZListObj.mbdate"
                            value-format="yyyy-MM-dd "
                            @change="getHZList"
                            placeholder="选择日期"
                          >
                          </el-date-picker>
                          -
                          <el-date-picker
                            style="width:168px;height:32px"
                            type="date"
                            v-model="getHZListObj.medate"
                            @change="getHZList"
                            value-format="yyyy-MM-dd "
                            placeholder="选择日期"
                          >
                          </el-date-picker>
                        </p>
                      </div>
                    </div>
                  </el-col>
                  <el-col :span="6">
                    <div class="grid-content bg-purple div_P">
                      <div class="form-group">
                        <p>
                          <label>申请医院:</label>
                          <select
                            class="form-control"
                            v-model="getHZListObj.hospname"
                            placeholder="请选择"
                            @change="getHZList"
                          >
                            <option
                              v-for="(item,index) in zzjgList"
                              :label="item.HospitalName"
                              :value="item.HospitalName"
                              :key="index"
                            ></option>
                          </select>
                        </p>
                      </div>
                    </div>
                  </el-col>

                </el-row>
              </div>
            </el-card>
            <el-table
              :data="huizhenList"
              height="326"
              border
              style="width: 100%"
            >
              <el-table-column
                fixed
                prop="Name"
                label="患者姓名"
                width="120"
              >
              </el-table-column>
              <el-table-column
                prop="Id"
                label="会诊编号"
                width="120"
              >
              </el-table-column>

              <el-table-column
                prop="SubscribeTime"
                label="申请时间"
                width="120"
              >
              </el-table-column>
              <el-table-column
                prop="Request"
                label="申请方"
              >
              </el-table-column>

              <el-table-column
                prop="Joins"
                label="参与方"
              >
              </el-table-column>
              <el-table-column
                prop="StatusName"
                label="状态"
              >
              </el-table-column>

              <el-table-column
                fixed="right"
                label="操作"
                width="160"
              >
                <template slot-scope="scope">
                  <el-button
                    @click="handleClickInforItem(scope.row)"
                    type="text"
                    size="small"
                  >查看详情
                  </el-button>
                </template>
              </el-table-column>
            </el-table>
            <el-pagination
              background
              layout="prev, pager, next"
              :page-size="10"
              @current-change="handleCurrentChange"
              :total="total"
            >
            </el-pagination>
          </div>
        </el-tab-pane>
      </el-tabs>

    </div>

    <!--弹框编辑详情-->
    <div
      class="blackBg hyCZBg"
      v-if="isShow=='InforUpdate'"
    >
      <div class="panel-default column2">
        <em
          class="closes"
          @click="showDialog('')"
        >×</em>
        <div class="panel-heading">会诊详情</div>
        <div class="InspectionCL22">
          <div class="dRightMain">
            <el-row>
              <el-col :span="3">
                <el-timeline>
                  <el-timeline-item
                    v-for="(activity, index) in activities"
                    :key="index"
                    :icon="activity.icon"
                    :type="activity.type"
                    :color="activity.color"
                    :size="activity.size"
                    :timestamp="activity.timestamp"
                  >
                    {{activity.content}}
                  </el-timeline-item>
                </el-timeline>
              </el-col>
              <el-col :span="21">
                <el-tabs v-model="activeName">
                  <el-tab-pane
                    label="会诊信息"
                    name="first"
                  >
                    <div
                      style="height: 528px;overflow: auto"
                      class="cardP"
                    >
                      <el-card class="box-card">
                        <div
                          slot="header"
                          class="clearfix"
                        >
                          <span>会诊基本信息</span>
                          <el-button
                            style="float: right; padding: 3px 0"
                            type="text"
                            v-if="false"
                          >
                            操作按钮
                          </el-button>
                        </div>
                        <div>
                          <el-row>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class=" form-group ">
                                  <p>
                                    <label>会诊方式:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult.ConType"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in hzfsList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>急诊情况:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult.isEm"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in jjqkList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class="form-group">
                                  <p>
                                    <label>申请类型:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult.ReqType"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in sqlxList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>是否交互式:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult.isAc"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in sfjhList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                          </el-row>
                        </div>
                      </el-card>
                      <el-card class="box-card">
                        <div
                          slot="header"
                          class="clearfix"
                        >
                          <span>会诊方信息</span>
                        </div>
                        <div>
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple div_P">
                                <div class=" form-group ">
                                  <p class="selectTime">
                                    <label>期望会诊日期:</label>
                                    <el-date-picker
                                      style="width:96px;height:32px"
                                      type="date"
                                      value-format="yyyy-MM-dd"
                                      v-model="huizhenObj.Consult.SubscribeTime"
                                      placeholder="选择日期"
                                    >
                                    </el-date-picker>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult.TimeFlag"
                                      placeholder="请选择"
                                      style=""
                                    >
                                      <option
                                        v-for="(item,index) in hzsjList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>

                                </div>
                              </div>
                            </el-col>
                            <el-col :span="12">
                              <div class="grid-content bg-purple-light div_P">
                                <button
                                  class="btn btn-default"
                                  @click="showDialogYS('YSLB')"
                                >
                                  添加会诊医生
                                </button>
                              </div>
                            </el-col>

                          </el-row>
                        </div>
                        <div class="fjtable">
                          <el-table
                            :data="huizhenObj.Consult_Joins"
                            height="112"
                            border
                            style="width: 100%"
                          >
                            <el-table-column
                              fixed
                              prop="Hospital"
                              label="所属医院"
                            >
                            </el-table-column>
                            <el-table-column
                              prop="Dept"
                              label="科室"
                            >
                            </el-table-column>
                            <el-table-column
                              prop="Doctor"
                              label="姓名"
                            >
                            </el-table-column>
                            <el-table-column
                              prop="Title"
                              label="擅长"
                            >
                            </el-table-column>
                            <el-table-column
                              prop="Describe"
                              label="简介"
                            >
                            </el-table-column>
                            <el-table-column
                              fixed="right"
                              label="是否主诊"
                              width="88"
                            >
                              <template slot-scope="scope">
                                <el-switch
                                  v-model="scope.row.IsMaster==1"
                                  active-color="#13ce66"
                                  inactive-color="#ff4949"
                                  @change="updateRow2YS(scope.$index, huizhenObj.Consult_Joins)"
                                >
                                </el-switch>

                              </template>
                            </el-table-column>
                            <el-table-column
                              fixed="right"
                              label="操作"
                              width="80"
                            >
                              <template slot-scope="scope">
                                <el-button
                                  type="text"
                                  size="small"
                                  @click.native.prevent="deleteRow2YS(scope.$index, huizhenObj.Consult_Joins)"
                                >
                                  删除
                                </el-button>
                              </template>
                            </el-table-column>
                          </el-table>
                        </div>
                      </el-card>
                      <el-card class="box-card">
                        <div
                          slot="header"
                          class="clearfix"
                        >
                          <span>申请方信息</span>
                        </div>
                        <div>
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple div_P">
                                <div v-if="false">
                                  <p>
                                    <label
                                      style="padding-right: 120px;padding-right: 80px"
                                    >填写方式:</label>
                                    <template style="margin-left: 38px">
                                      <el-radio
                                        v-model="radio"
                                        label="1"
                                      >系统关联</el-radio>
                                      <el-radio
                                        v-model="radio"
                                        label="2"
                                      >手工录入</el-radio>
                                    </template>
                                  </p>

                                </div>
                              </div>
                            </el-col>
                            <el-col :span="12">

                            </el-col>

                          </el-row>
                          <div v-if="radio==2">
                            <el-row>
                              <el-col :span="6">
                                <div class="grid-content bg-purple div_P">
                                  <div class=" form-group ">
                                    <p>
                                      <label>申请医院:</label>
                                      <select
                                        class="form-control"
                                        v-model="model_clinic_typeC"
                                        placeholder="请选择"
                                      >
                                        <option
                                          v-for="(item,index) in hzfsList"
                                          :label="item.name"
                                          :value="item.code"
                                          :key="index"
                                        ></option>
                                      </select>
                                    </p>
                                  </div>
                                </div>
                              </el-col>
                              <el-col :span="6">
                                <div class="grid-content bg-purple-light div_P">
                                  <div class="form-group">
                                    <p>
                                      <label>申请科室:</label>
                                      <select
                                        class="form-control"
                                        v-model="model_clinic_typeC"
                                        placeholder="请选择"
                                      >
                                        <option
                                          v-for="(item,index) in jjqkList"
                                          :label="item.name"
                                          :value="item.code"
                                          :key="index"
                                        ></option>
                                      </select>
                                    </p>
                                  </div>
                                </div>
                              </el-col>
                              <el-col :span="6">
                                <div class="grid-content bg-purple div_P">
                                  <div class="form-group">
                                    <p>
                                      <label>申请子科室:</label>
                                      <select
                                        class="form-control"
                                        v-model="model_clinic_typeC"
                                        placeholder="请选择"
                                      >
                                        <option
                                          v-for="(item,index) in sqlxList"
                                          :label="item.name"
                                          :value="item.code"
                                          :key="index"
                                        ></option>
                                      </select>
                                    </p>
                                  </div>
                                </div>
                              </el-col>
                              <el-col :span="6">
                                <div class="grid-content bg-purple-light div_P">
                                  <div class="form-group">
                                    <p>
                                      <label>申请医生:</label>
                                      <select
                                        class="form-control"
                                        v-model="model_clinic_typeC"
                                        placeholder="请选择"
                                      >
                                        <option
                                          v-for="(item,index) in sfjhList"
                                          :label="item.name"
                                          :value="item.code"
                                          :key="index"
                                        ></option>
                                      </select>
                                    </p>
                                  </div>
                                </div>
                              </el-col>
                            </el-row>
                          </div>
                          <div v-if="radio==1">
                            <el-row>
                              <el-col :span="6">
                                <div class="grid-content bg-purple div_P">
                                  <div class=" form-group ">
                                    <p>
                                      <label>申请医院:</label>
                                      <input
                                        type="text"
                                        class="form-control"
                                        disabled
                                        v-model="huizhenObj.Consult.Hospital"
                                        placeholder="必填"
                                      >
                                      </input>
                                    </p>
                                  </div>
                                </div>
                              </el-col>
                              <el-col :span="6">
                                <div class="grid-content bg-purple-light div_P">
                                  <div class="form-group">
                                    <p>
                                      <label>申请科室:</label>
                                      <input
                                        type="text"
                                        class="form-control"
                                        disabled
                                        v-model="huizhenObj.Consult.Dept"
                                        placeholder="必填"
                                      >
                                      </input>
                                    </p>
                                  </div>
                                </div>
                              </el-col>

                              <el-col :span="6">
                                <div class="grid-content bg-purple-light div_P">
                                  <div class="form-group">
                                    <p>
                                      <label>申请医生:</label>
                                      <input
                                        type="text"
                                        class="form-control"
                                        disabled
                                        v-model="huizhenObj.Consult.Doctor"
                                        placeholder="必填"
                                      >
                                      </input>
                                    </p>
                                  </div>
                                </div>
                              </el-col>
                            </el-row>
                          </div>
                        </div>
                      </el-card>
                    </div>
                  </el-tab-pane>
                  <el-tab-pane
                    label="患者信息"
                    name="second"
                  >
                    <div
                      style="height: 500px;overflow: auto"
                      class="cardP"
                    >
                      <el-card class="box-card">
                        <div
                          slot="header"
                          class="clearfix"
                        >
                          <span>患者信息</span>
                          <button
                            type="button"
                            class="btn btn-primary"
                            v-if="false"
                            style="float: right; padding: 3px 12px"
                          >
                            导入
                          </button>
                        </div>
                        <div>
                          <el-row>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class=" form-group ">
                                  <p>
                                    <label>申请类型:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult_Patient.Catagory"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in sqlxList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>患者姓名:</label>
                                    <input
                                      type="text"
                                      class="form-control"
                                      v-model="huizhenObj.Consult_Patient.Name"
                                      placeholder="必填"
                                    >
                                    </input>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class="form-group">
                                  <p class="selectTime">
                                    <label>出生日期:</label>
                                    <el-date-picker
                                      style="width:96px;height:32px"
                                      type="date"
                                      v-model="huizhenObj.Consult_Patient.Born"
                                      value-format="yyyy-MM-dd "
                                      placeholder="选择日期"
                                    >
                                    </el-date-picker>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>年龄:</label>
                                    <input
                                      type="text"
                                      class="form-control"
                                      style="width: 60px"
                                      v-model="huizhenObj.Consult_Patient.Age"
                                      placeholder="必填"
                                    >
                                    </input>
                                    <select
                                      class="form-control"
                                      style="width: 50px;margin-left: 10px"
                                      v-model="huizhenObj.Consult_Patient.AgeUnit"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in nldwList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                          </el-row>
                          <el-row>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class=" form-group ">
                                  <p>
                                    <label>性别:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult_Patient.Sex"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in xbList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>体重:</label>
                                    <input
                                      type="text"
                                      class="form-control"
                                      v-model="huizhenObj.Consult_Patient.Weight"
                                      placeholder="必填"
                                    >
                                    </input>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class="form-group">
                                  <p class="selectTime">
                                    <label>身高:</label>
                                    <input
                                      type="text"
                                      class="form-control"
                                      v-model="huizhenObj.Consult_Patient.Height"
                                      placeholder="必填"
                                    >
                                    </input>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>BMI:</label>
                                    <input
                                      type="text"
                                      class="form-control"
                                      v-model="huizhenObj.Consult_Patient.BMI"
                                      placeholder="必填"
                                    >
                                    </input>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                          </el-row>
                          <el-row>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class=" form-group ">
                                  <p>
                                    <label>婚姻情况:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult_Patient.Marital"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in hyqkList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>患者病情:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult_Patient.Condition"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in hzbqList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class="form-group">
                                  <p class="selectTime">
                                    <label>入院时间:</label>
                                    <el-date-picker
                                      style="width:96px;height:32px"
                                      type="date"
                                      v-model="huizhenObj.Consult_Patient.InDate"
                                      value-format="yyyy-MM-dd"
                                      placeholder="选择日期"
                                    >
                                    </el-date-picker>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>电话:</label>
                                    <input
                                      type="text"
                                      class="form-control"
                                      style="width: 110px"
                                      v-model="huizhenObj.Consult_Patient.TelePhone"
                                      placeholder="必填"
                                    >
                                    </input>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                          </el-row>
                          <el-row>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class=" form-group ">
                                  <p>
                                    <label>医保类别:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult_Patient.MedicalCatagory"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in yblbList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>医保卡号:</label>
                                    <input
                                      type="text"
                                      class="form-control"
                                      v-model="huizhenObj.Consult_Patient.MedicalCard"
                                      placeholder="必填"
                                    >
                                    </input>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class="form-group">
                                  <p class="selectTime">
                                    <label>就诊科室:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult_Patient.Dept"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in deptList"
                                        :label="item.Name"
                                        :value="item.Id"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>就诊类型:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult_Patient.SeekCatagory"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in jzlxList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                          </el-row>
                          <el-row>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class=" form-group ">
                                  <p>
                                    <label>国籍:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult_Patient.Country"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in gjList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>民族:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult_Patient.Nation"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in mzList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class="form-group">
                                  <p class="selectTime">
                                    <label>职业:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult_Patient.Occupation"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in zyList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>地址:</label>
                                    <input
                                      type="text"
                                      class="form-control"
                                      v-model="huizhenObj.Consult_Patient.Address"
                                      placeholder="必填"
                                    >
                                    </input>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                          </el-row>
                        </div>
                      </el-card>

                    </div>
                  </el-tab-pane>
                  <el-tab-pane
                    label="病历摘要"
                    name="third"
                  >
                    <div class="cardP">
                      <el-card class="box-card">
                        <div
                          slot="header"
                          class="clearfix"
                        >
                          <span>病历摘要</span>
                          <el-button
                            style="float: right; padding: 3px 0"
                            type="text"
                            v-if="false"
                          >
                            操作按钮
                          </el-button>
                        </div>
                        <div
                          class="cardC"
                          style="height: 400px;overflow-y: auto"
                        >
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>患者主诉</span>
                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      placeholder="字数限制200"
                                      maxlength="200"
                                      show-word-limit
                                      v-model="huizhenObj.Consult_Patient_Remark.ZhuSu"
                                    >
                                    </el-input>
                                  </div>

                                </el-card>
                              </div>
                            </el-col>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>现病史</span>

                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      placeholder="字数限制200"
                                      maxlength="200"
                                      show-word-limit
                                      v-model="huizhenObj.Consult_Patient_Remark.XianBingShi"
                                    >
                                    </el-input>
                                  </div>

                                </el-card>
                              </div>
                            </el-col>

                          </el-row>
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>既往史、个人史、家族史</span>
                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      placeholder="字数限制1000"
                                      maxlength="1000"
                                      show-word-limit
                                      v-model="huizhenObj.Consult_Patient_Remark.JiWangShi"
                                    >
                                    </el-input>
                                  </div>

                                </el-card>
                              </div>
                            </el-col>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>体格检查</span>

                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      placeholder="字数限制1000"
                                      maxlength="1000"
                                      show-word-limit
                                      v-model="huizhenObj.Consult_Patient_Remark.TiGeJianCha"
                                    >
                                    </el-input>
                                  </div>

                                </el-card>
                              </div>
                            </el-col>

                          </el-row>
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>辅助检查结果</span>
                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      placeholder="字数限制1000"
                                      maxlength="1000"
                                      show-word-limit
                                      v-model="huizhenObj.Consult_Patient_Remark.FuZhuJianCha"
                                    >
                                    </el-input>
                                  </div>

                                </el-card>
                              </div>
                            </el-col>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>初步诊断</span>

                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      placeholder="字数限制1000"
                                      maxlength="1000"
                                      show-word-limit
                                      v-model="huizhenObj.Consult_Patient_Remark.ChuBuZhenDuan"
                                    >
                                    </el-input>
                                  </div>

                                </el-card>
                              </div>
                            </el-col>

                          </el-row>
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>治疗经过</span>
                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      placeholder="字数限制1000"
                                      maxlength="1000"
                                      show-word-limit
                                      v-model="huizhenObj.Consult_Patient_Remark.ZhiLiaoJingGuo"
                                    >
                                    </el-input>
                                  </div>

                                </el-card>
                              </div>
                            </el-col>
                            <el-col :span="12">

                            </el-col>

                          </el-row>
                        </div>
                      </el-card>
                    </div>
                  </el-tab-pane>
                  <el-tab-pane
                    label="检查检验"
                    name="fourth"
                  >
                    <div class="cardP">
                      <el-card class="box-card">
                        <div
                          slot="header"
                          class="clearfix"
                        >
                          <span>检查检验</span>
                          <el-button
                            style="float: right; padding: 3px 0"
                            type="text"
                            v-if="false"
                          >
                            操作按钮
                          </el-button>
                        </div>
                        <div
                          class="cardC"
                          style="height: 400px;overflow-y: auto"
                        >
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>影像检查</span>
                                    <el-button
                                      type="success"
                                      style="float: right; padding: 3px 0"
                                      @click="showDialogYS('JCLB')"
                                    >上传
                                      <i
                                        class="el-icon-upload el-icon--right"></i>
                                    </el-button>
                                  </div>
                                  <div class="fjtable">
                                    <el-table
                                      :data="huizhenObj.Consult_CheckRecords"
                                      height="112"
                                      border
                                      style="width: 100%"
                                    >
                                      <el-table-column
                                        fixed
                                        prop="StudyId"
                                        label="检查号"
                                        width="150"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="CheckTime"
                                        label="检查时间"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="Device"
                                        label="设备名称"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="Modality"
                                        label="检查类型"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="StudyDesc"
                                        label="检查描述"
                                        width="120"
                                      >
                                      </el-table-column>

                                      <el-table-column
                                        fixed="right"
                                        label="操作"
                                        width="100"
                                      >
                                        <template slot-scope="scope">
                                          <el-button
                                            @click="handleClickJCItem(scope.row)"
                                            type="text"
                                            size="small"
                                          >查看
                                          </el-button>
                                          <el-button
                                            type="text"
                                            size="small"
                                            @click.native.prevent="deleteRow2JC(scope.$index, huizhenObj.Consult_CheckRecords)"
                                          >
                                            删除
                                          </el-button>
                                        </template>
                                      </el-table-column>
                                    </el-table>
                                  </div>
                                </el-card>
                              </div>
                            </el-col>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>病理检查</span>
                                    <el-button
                                      type="success"
                                      style="float: right; padding: 3px 0"
                                      @click="showDialogYS('BLLB')"
                                    >上传
                                      <i
                                        class="el-icon-upload el-icon--right"></i>
                                    </el-button>
                                  </div>
                                  <div class="fjtable">
                                    <el-table
                                      :data="huizhenObj.Consult_PathologyRecords"
                                      height="112"
                                      border
                                      style="width: 100%"
                                    >
                                      <el-table-column
                                        fixed
                                        prop="StudyId"
                                        label="检查编号"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        fixed
                                        prop="CheckTime"
                                        label="检查时间"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        fixed
                                        prop="Device"
                                        label="检查设备"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        fixed
                                        prop="Modality"
                                        label="检查类别"
                                        width="120"
                                      >
                                      </el-table-column>

                                      <el-table-column
                                        prop="StudyDesc"
                                        label="检查说明"
                                      >
                                      </el-table-column>

                                      <el-table-column
                                        fixed="right"
                                        label="操作"
                                        width="100"
                                      >
                                        <template slot-scope="scope">
                                          <el-button
                                            @click="handleClickBLItem(scope.row)"
                                            type="text"
                                            size="small"
                                          >查看
                                          </el-button>
                                          <el-button
                                            type="text"
                                            size="small"
                                            @click.native.prevent="deleteRow2BL(scope.$index, huizhenObj.Consult_PathologyRecords)"
                                          >
                                            删除
                                          </el-button>
                                        </template>
                                      </el-table-column>
                                    </el-table>
                                  </div>
                                </el-card>
                              </div>
                            </el-col>
                          </el-row>
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>检验诊断</span>
                                    <el-button
                                      type="success"
                                      style="float: right; padding: 3px 0"
                                      @click="showDialogYS('JYLB')"
                                    >上传
                                      <i
                                        class="el-icon-upload el-icon--right"></i>
                                    </el-button>
                                  </div>
                                  <div class="fjtable">
                                    <el-table
                                      :data="huizhenObj.Consult_TestRecords"
                                      height="112"
                                      border
                                      style="width: 100%"
                                    >
                                      <el-table-column
                                        fixed
                                        prop="TestId"
                                        label="化验单编号"
                                        width="150"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        fixed
                                        prop="ItemName"
                                        label="结果项目名称"
                                        width="150"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="TestTime"
                                        label="化验时间"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="Result"
                                        label="数值"
                                        width="80"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="Unit"
                                        label="单位"
                                        width="80"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="RRS"
                                        label="参考范围"
                                        width="120"
                                      >
                                      </el-table-column>

                                      <el-table-column
                                        fixed="right"
                                        label="操作"
                                        width="100"
                                      >
                                        <template slot-scope="scope">
                                          <el-button
                                            v-if="false"
                                            @click="handleClickJYItem(scope.row)"
                                            type="text"
                                            size="small"
                                          >查看
                                          </el-button>
                                          <el-button
                                            type="text"
                                            size="small"
                                            @click.native.prevent="deleteRow2JY(scope.$index, huizhenObj.Consult_TestRecords)"
                                          >
                                            删除
                                          </el-button>
                                        </template>
                                      </el-table-column>
                                    </el-table>
                                  </div>
                                </el-card>
                              </div>
                            </el-col>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>心电检查</span>
                                    <el-button
                                      type="success"
                                      style="float: right; padding: 3px 0"
                                      @click="showDialogYS('XDLB')"
                                    >上传
                                      <i
                                        class="el-icon-upload el-icon--right"></i>
                                    </el-button>
                                  </div>
                                  <div class="fjtable">
                                    <el-table
                                      :data="huizhenObj.Consult_ECGRecords"
                                      height="112"
                                      border
                                      style="width: 100%"
                                    >
                                      <el-table-column
                                        fixed
                                        prop="StudyId"
                                        label="检查编号"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        fixed
                                        prop="Device"
                                        label="检查设备"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        fixed
                                        prop="Modality"
                                        label="检查类别"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="CheckTime"
                                        label="检查时间"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="StudyDesc"
                                        label="检查说明"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        fixed="right"
                                        label="操作"
                                        width="100"
                                      >
                                        <template slot-scope="scope">
                                          <el-button
                                            @click="handleClickXDItem(scope.row)"
                                            type="text"
                                            size="small"
                                          >查看
                                          </el-button>
                                          <el-button
                                            type="text"
                                            size="small"
                                            @click.native.prevent="deleteRow2XD(scope.$index, huizhenObj.Consult_ECGRecords)"
                                          >
                                            删除
                                          </el-button>
                                        </template>
                                      </el-table-column>
                                    </el-table>
                                  </div>
                                </el-card>
                              </div>
                            </el-col>
                          </el-row>
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>相关附件</span>
                                    <el-button
                                      type="success"
                                      style="float: right; padding: 3px 0"
                                      @click="showDialogYS('PZ')"
                                    >
                                      拍照
                                      <i
                                        class="el-icon-upload el-icon--right"></i>
                                    </el-button>
                                  </div>
                                  <div class="fjtable selectPic">
                                    <el-upload
                                      ref='upload'
                                      :auto-upload='false'
                                      :file-list="fileList"
                                      :multiple='false'
                                      :limit="12"
                                      :on-exceed="handleExceed"
                                      :http-request="uploadFiles"
                                      accept="image/jpeg,image/gif,image/png"
                                      action=''
                                      list-type="picture"
                                      :on-change='changeUpload'
                                    >
                                      <el-button
                                        slot="trigger"
                                        size="mini"
                                        type="primary"
                                      >选取图片
                                      </el-button>
                                      <span>&nbsp;</span>

                                    </el-upload>
                                  </div>
                                  <el-table
                                    :data="filePICList"
                                    style="width: 100%"
                                    max-height="150"
                                  >

                                    <el-table-column
                                      fixed="right"
                                      label="图片"
                                    >
                                      <template slot-scope="scope">

                                        <el-image
                                          style="width: 80px; height: 80px"
                                          :src="scope.row.picPth"
                                          :fit="fill"
                                        ></el-image>
                                      </template>
                                    </el-table-column>

                                    <el-table-column
                                      fixed="right"
                                      label="操作"
                                      width="180"
                                    >
                                      <template slot-scope="scope">
                                        <el-button
                                          @click.native.prevent="deleteRowPIC(scope.$index, filePICList)"
                                          type="text"
                                          size="small"
                                        >
                                          移除
                                        </el-button>
                                      </template>
                                    </el-table-column>
                                  </el-table>
                                </el-card>
                              </div>
                            </el-col>
                            <el-col :span="12">

                            </el-col>

                          </el-row>
                        </div>
                      </el-card>
                    </div>
                  </el-tab-pane>
                  <el-tab-pane
                    label="辅助检查"
                    name="5"
                  >
                    <div class="cardP">
                      <el-card class="box-card">
                        <div
                          slot="header"
                          class="clearfix"
                        >
                          <span>辅助检查</span>
                          <el-button
                            style="float: right; padding: 3px 0"
                            type="text"
                            v-if="false"
                          >
                            操作按钮
                          </el-button>
                        </div>
                        <div
                          class="cardC"
                          style="height: 400px;overflow-y: auto"
                        >
                          <el-row>
                            <el-col :span="24">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>会诊目的</span>
                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      placeholder="字数限制2000"
                                      maxlength="2000"
                                      show-word-limit
                                      v-model="huizhenObj.Consult.Goal"
                                    >
                                    </el-input>
                                  </div>

                                </el-card>
                              </div>
                            </el-col>
                          </el-row>
                          <el-row>
                            <el-col :span="24">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>补充说明</span>
                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      placeholder="字数限制1000"
                                      maxlength="1000"
                                      show-word-limit
                                      v-model="huizhenObj.Consult.Describe"
                                    >
                                    </el-input>
                                  </div>
                                </el-card>
                              </div>
                            </el-col>
                          </el-row>
                        </div>
                      </el-card>
                    </div>
                  </el-tab-pane>
                  <el-tab-pane
                    label="会诊报告"
                    v-if=" huizhenObj.Consult.Status>=4"
                    name="6"
                  >
                    <div class="cardP">
                      <el-row>
                        <el-col :span="12">
                          <el-card class="box-card">
                            <div
                              slot="header"
                              class="clearfix"
                            >
                              <span>会诊报告</span>
                              <el-button
                                style="float: right; padding: 3px 0"
                                type="text"
                                v-if="false"
                                @click="finishHZ(4)"
                              >
                                结束会诊
                              </el-button>
                            </div>
                            <div
                              class="cardC"
                              style="height: 400px;overflow-y: auto"
                            >
                              <div
                                v-for="obj in HZBGList"
                                :key="obj"
                                class="text item"
                              >

                                <el-card class="box-card">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>{{obj.ReportUser}}</span>
                                    <el-button
                                      style="float: right; padding: 3px 0"
                                      type="text"
                                      v-if="false"
                                    >删除
                                    </el-button>
                                  </div>
                                  <p>
                                    <span
                                      style="color: #00b3ee;">报告时间：{{obj.ReportTime}}</span>
                                  </p>
                                  <p>
                                    <span>诊断意见：</span>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      disabled
                                      placeholder="字数限制200"
                                      maxlength="200"
                                      show-word-limit
                                      v-model="obj.Diagnosis"
                                    >
                                    </el-input>
                                  </p>
                                  <p>
                                    <span>处理措施：</span>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      disabled
                                      placeholder="字数限制200"
                                      maxlength="200"
                                      show-word-limit
                                      v-model="obj.Treatment"
                                    >
                                    </el-input>
                                  </p>
                                </el-card>
                              </div>
                            </div>
                          </el-card>
                        </el-col>
                        <el-col :span="12">
                          <el-card class="box-card">
                            <div
                              slot="header"
                              class="clearfix"
                            >
                              <span>我的报告</span>
                              <el-button
                                style="float: right; padding: 3px 0"
                                type="text"
                                @click="addHZBG()"
                              >
                                提交
                              </el-button>
                            </div>
                            <div
                              class="cardC"
                              style="height: 400px;overflow-y: auto"
                            >
                              <el-row>
                                <el-col :span="24">
                                  <div class="grid-content bg-purple ">
                                    <el-card style="width: 100%">
                                      <div
                                        slot="header"
                                        class="clearfix"
                                      >
                                        <span>诊断意见</span>
                                      </div>
                                      <div>
                                        <el-input
                                          type="textarea"
                                          :rows="4"
                                          placeholder="字数限制200"
                                          maxlength="200"
                                          show-word-limit
                                          v-model="HZBGObj.Diagnosis"
                                        >
                                        </el-input>
                                      </div>
                                    </el-card>
                                  </div>
                                </el-col>
                              </el-row>
                              <el-row>
                                <el-col :span="24">
                                  <div class="grid-content bg-purple ">
                                    <el-card style="width: 100%">
                                      <div
                                        slot="header"
                                        class="clearfix"
                                      >
                                        <span>处理措施</span>
                                      </div>
                                      <div>
                                        <el-input
                                          type="textarea"
                                          :rows="4"
                                          placeholder="字数限制1000"
                                          maxlength="1000"
                                          show-word-limit
                                          v-model="HZBGObj.Treatment"
                                        >
                                        </el-input>
                                      </div>
                                    </el-card>
                                  </div>
                                </el-col>
                              </el-row>

                            </div>
                          </el-card>
                        </el-col>
                      </el-row>
                    </div>
                  </el-tab-pane>
                </el-tabs>
              </el-col>
            </el-row>
            <el-row style="margin-top: 16px">
              <el-col :span="12">
                <el-link disabled></el-link>
              </el-col>
              <el-col :span="12">
                <div class="grid-content bg-purple-light div_P">
                  <el-button
                    type="success"
                    plain
                    @click="addHZObj2()"
                  >提交</el-button>

                </div>
              </el-col>

            </el-row>
          </div>
        </div>
      </div>

    </div>

    <!--弹框详情-->
    <div
      class="blackBg hyCZBg"
      v-if="isShow=='Infor'"
    >
      <div class="panel-default column2">
        <em
          class="closes"
          @click="showDialog('')"
        >×</em>
        <div class="panel-heading">会诊详情</div>
        <div class="InspectionCL22">
          <div class="dRightMain">
            <el-row>
              <el-col :span="3">
                <el-timeline>
                  <el-timeline-item
                    v-for="(activity, index) in activities"
                    :key="index"
                    :icon="activity.icon"
                    :type="activity.type"
                    :color="activity.color"
                    :size="activity.size"
                    :timestamp="activity.timestamp"
                  >
                    {{activity.content}}
                  </el-timeline-item>
                </el-timeline>
              </el-col>
              <el-col :span="21">
                <el-tabs v-model="activeName">
                  <el-tab-pane
                    label="会诊信息"
                    name="first"
                  >
                    <div
                      style="height: 528px;overflow: auto"
                      class="cardP"
                    >
                      <el-card class="box-card">
                        <div
                          slot="header"
                          class="clearfix"
                        >
                          <span>会诊基本信息</span>
                          <el-button
                            style="float: right; padding: 3px 0"
                            type="text"
                            v-if="false"
                          >
                            操作按钮
                          </el-button>
                        </div>
                        <div>
                          <el-row>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class=" form-group ">
                                  <p>
                                    <label>会诊方式:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult.ConType"
                                      disabled
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in hzfsList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>急诊情况:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult.isEm"
                                      disabled
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in jjqkList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class="form-group">
                                  <p>
                                    <label>申请类型:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult.ReqType"
                                      disabled
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in sqlxList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>是否交互式:</label>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult.isAc"
                                      disabled
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in sfjhList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                          </el-row>
                        </div>
                      </el-card>
                      <el-card class="box-card">
                        <div
                          slot="header"
                          class="clearfix"
                        >
                          <span>会诊方信息</span>
                        </div>
                        <div>
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple div_P">
                                <div class=" form-group ">
                                  <p class="selectTime">
                                    <label>期望会诊日期:</label>
                                    <el-date-picker
                                      style="width:96px;height:32px"
                                      type="date"
                                      disabled
                                      value-format="yyyy-MM-dd"
                                      v-model="huizhenObj.Consult.SubscribeTime"
                                      placeholder="选择日期"
                                    >
                                    </el-date-picker>
                                    <select
                                      class="form-control"
                                      v-model="huizhenObj.Consult.TimeFlag"
                                      disabled
                                      placeholder="请选择"
                                      style=""
                                    >
                                      <option
                                        v-for="(item,index) in hzsjList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>

                                </div>
                              </div>
                            </el-col>
                            <el-col :span="12">
                              <div
                                class="grid-content bg-purple-light div_P"
                                v-if="false"
                              >
                                <button
                                  class="btn btn-default"
                                  @click="showDialog('YSLB')"
                                >
                                  添加会诊医生
                                </button>
                              </div>
                            </el-col>

                          </el-row>
                        </div>
                        <div class="fjtable">
                          <el-table
                            :data="huizhenObj.Consult_Joins"
                            height="112"
                            border
                            style="width: 100%"
                          >
                            <el-table-column
                              fixed
                              prop="Hospital"
                              label="所属医院"
                            >
                            </el-table-column>
                            <el-table-column
                              prop="Dept"
                              label="科室"
                            >
                            </el-table-column>
                            <el-table-column
                              prop="Doctor"
                              label="姓名"
                            >
                            </el-table-column>
                            <el-table-column
                              prop="Title"
                              label="擅长"
                            >
                            </el-table-column>
                            <el-table-column
                              prop="Describe"
                              label="简介"
                            >
                            </el-table-column>
                            <el-table-column
                              fixed="right"
                              label="是否主诊"
                              width="88"
                            >
                              <template slot-scope="scope">
                                <el-switch
                                  v-model="scope.row.IsMaster==1"
                                  disabled
                                  active-color="#13ce66"
                                  inactive-color="#ff4949"
                                  @change="updateRow2YS(scope.$index, huizhenObj.Consult_Joins)"
                                >
                                </el-switch>

                              </template>
                            </el-table-column>
                            <el-table-column
                              fixed="right"
                              label="操作"
                              width="80"
                              v-if="false"
                            >
                              <template slot-scope="scope">
                                <el-button
                                  type="text"
                                  size="small"
                                  @click.native.prevent="deleteRow2YS(scope.$index, huizhenObj.Consult_Joins)"
                                >
                                  删除
                                </el-button>
                              </template>
                            </el-table-column>
                          </el-table>
                        </div>
                      </el-card>
                      <el-card class="box-card">
                        <div
                          slot="header"
                          class="clearfix"
                        >
                          <span>申请方信息</span>
                        </div>
                        <div>
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple div_P">
                                <div v-if="false">
                                  <p>
                                    <label
                                      style="padding-right: 120px;padding-right: 80px"
                                    >填写方式:</label>
                                    <template style="margin-left: 38px">
                                      <el-radio
                                        v-model="radio"
                                        label="1"
                                      >系统关联
                                      </el-radio>
                                      <el-radio
                                        v-model="radio"
                                        label="2"
                                      >手工录入
                                      </el-radio>
                                    </template>
                                  </p>

                                </div>
                              </div>
                            </el-col>
                            <el-col :span="12">

                            </el-col>

                          </el-row>
                          <div v-if="radio==2">
                            <el-row>
                              <el-col :span="6">
                                <div class="grid-content bg-purple div_P">
                                  <div class=" form-group ">
                                    <p>
                                      <label>申请医院:</label>
                                      <select
                                        class="form-control"
                                        v-model="model_clinic_typeC"
                                        placeholder="请选择"
                                      >
                                        <option
                                          v-for="(item,index) in hzfsList"
                                          :label="item.name"
                                          :value="item.code"
                                          :key="index"
                                        ></option>
                                      </select>
                                    </p>
                                  </div>
                                </div>
                              </el-col>
                              <el-col :span="6">
                                <div class="grid-content bg-purple-light div_P">
                                  <div class="form-group">
                                    <p>
                                      <label>申请科室:</label>
                                      <select
                                        class="form-control"
                                        v-model="model_clinic_typeC"
                                        placeholder="请选择"
                                      >
                                        <option
                                          v-for="(item,index) in jjqkList"
                                          :label="item.name"
                                          :value="item.code"
                                          :key="index"
                                        ></option>
                                      </select>
                                    </p>
                                  </div>
                                </div>
                              </el-col>
                              <el-col :span="6">
                                <div class="grid-content bg-purple div_P">
                                  <div class="form-group">
                                    <p>
                                      <label>申请子科室:</label>
                                      <select
                                        class="form-control"
                                        v-model="model_clinic_typeC"
                                        placeholder="请选择"
                                      >
                                        <option
                                          v-for="(item,index) in sqlxList"
                                          :label="item.name"
                                          :value="item.code"
                                          :key="index"
                                        ></option>
                                      </select>
                                    </p>
                                  </div>
                                </div>
                              </el-col>
                              <el-col :span="6">
                                <div class="grid-content bg-purple-light div_P">
                                  <div class="form-group">
                                    <p>
                                      <label>申请医生:</label>
                                      <select
                                        class="form-control"
                                        v-model="model_clinic_typeC"
                                        placeholder="请选择"
                                      >
                                        <option
                                          v-for="(item,index) in sfjhList"
                                          :label="item.name"
                                          :value="item.code"
                                          :key="index"
                                        ></option>
                                      </select>
                                    </p>
                                  </div>
                                </div>
                              </el-col>
                            </el-row>
                          </div>
                          <div v-if="radio==1">
                            <el-row>
                              <el-col :span="6">
                                <div class="grid-content bg-purple div_P">
                                  <div class=" form-group ">
                                    <p>
                                      <label>申请医院:</label>
                                      <input
                                        type="text"
                                        class="form-control"
                                        disabled
                                        v-model="huizhenObj.Consult.Hospital"
                                        placeholder="必填"
                                      >
                                      </input>
                                    </p>
                                  </div>
                                </div>
                              </el-col>
                              <el-col :span="6">
                                <div class="grid-content bg-purple-light div_P">
                                  <div class="form-group">
                                    <p>
                                      <label>申请科室:</label>
                                      <input
                                        type="text"
                                        class="form-control"
                                        disabled
                                        v-model="huizhenObj.Consult.Dept"
                                        placeholder="必填"
                                      >
                                      </input>
                                    </p>
                                  </div>
                                </div>
                              </el-col>

                              <el-col :span="6">
                                <div class="grid-content bg-purple-light div_P">
                                  <div class="form-group">
                                    <p>
                                      <label>申请医生:</label>
                                      <input
                                        type="text"
                                        class="form-control"
                                        disabled
                                        v-model="huizhenObj.Consult.Doctor"
                                        placeholder="必填"
                                      >
                                      </input>
                                    </p>
                                  </div>
                                </div>
                              </el-col>
                            </el-row>
                          </div>
                        </div>
                      </el-card>
                    </div>
                  </el-tab-pane>
                  <el-tab-pane
                    label="患者信息"
                    name="second"
                  >
                    <div
                      style="height: 500px;overflow: auto"
                      class="cardP"
                    >
                      <el-card class="box-card">
                        <div
                          slot="header"
                          class="clearfix"
                        >
                          <span>患者信息</span>
                          <button
                            type="button"
                            class="btn btn-primary"
                            v-if="false"
                            style="float: right; padding: 3px 12px"
                          >
                            导入
                          </button>
                        </div>
                        <div>
                          <el-row>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class=" form-group ">
                                  <p>
                                    <label>申请类型:</label>
                                    <select
                                      class="form-control"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.Catagory"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in sqlxList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>患者姓名:</label>
                                    <input
                                      type="text"
                                      class="form-control"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.Name"
                                      placeholder="必填"
                                    >
                                    </input>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class="form-group">
                                  <p class="selectTime">
                                    <label>出生日期:</label>
                                    <el-date-picker
                                      style="width:96px;height:32px"
                                      type="date"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.Born"
                                      value-format="yyyy-MM-dd "
                                      placeholder="选择日期"
                                    >
                                    </el-date-picker>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>年龄:</label>
                                    <input
                                      type="text"
                                      class="form-control"
                                      style="width: 60px"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.Age"
                                      placeholder="必填"
                                    >
                                    </input>
                                    <select
                                      class="form-control"
                                      style="width: 50px;margin-left: 10px"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.AgeUnit"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in nldwList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                          </el-row>
                          <el-row>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class=" form-group ">
                                  <p>
                                    <label>性别:</label>
                                    <select
                                      class="form-control"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.Sex"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in xbList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>体重:</label>
                                    <input
                                      type="text"
                                      class="form-control"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.Weight"
                                      placeholder="必填"
                                    >
                                    </input>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class="form-group">
                                  <p class="selectTime">
                                    <label>身高:</label>
                                    <input
                                      type="text"
                                      class="form-control"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.Height"
                                      placeholder="必填"
                                    >
                                    </input>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>BMI:</label>
                                    <input
                                      type="text"
                                      class="form-control"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.BMI"
                                      placeholder="必填"
                                    >
                                    </input>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                          </el-row>
                          <el-row>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class=" form-group ">
                                  <p>
                                    <label>婚姻情况:</label>
                                    <select
                                      class="form-control"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.Marital"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in hyqkList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>患者病情:</label>
                                    <select
                                      class="form-control"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.Condition"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in hzbqList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class="form-group">
                                  <p class="selectTime">
                                    <label>入院时间:</label>
                                    <el-date-picker
                                      style="width:96px;height:32px"
                                      type="date"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.InDate"
                                      value-format="yyyy-MM-dd"
                                      placeholder="选择日期"
                                    >
                                    </el-date-picker>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>电话:</label>
                                    <input
                                      type="text"
                                      class="form-control"
                                      style="width: 110px"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.TelePhone"
                                      placeholder="必填"
                                    >
                                    </input>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                          </el-row>
                          <el-row>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class=" form-group ">
                                  <p>
                                    <label>医保类别:</label>
                                    <select
                                      class="form-control"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.MedicalCatagory"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in yblbList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>医保卡号:</label>
                                    <input
                                      type="text"
                                      class="form-control"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.MedicalCard"
                                      placeholder="必填"
                                    >
                                    </input>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class="form-group">
                                  <p class="selectTime">
                                    <label>就诊科室:</label>
                                    <select
                                      class="form-control"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.Dept"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in deptList"
                                        :label="item.Name"
                                        :value="item.Id"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>就诊类型:</label>
                                    <select
                                      class="form-control"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.SeekCatagory"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in jzlxList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                          </el-row>
                          <el-row>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class=" form-group ">
                                  <p>
                                    <label>国籍:</label>
                                    <select
                                      class="form-control"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.Country"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in gjList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>民族:</label>
                                    <select
                                      class="form-control"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.Nation"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in mzList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple div_P">
                                <div class="form-group">
                                  <p class="selectTime">
                                    <label>职业:</label>
                                    <select
                                      class="form-control"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.Occupation"
                                      placeholder="请选择"
                                    >
                                      <option
                                        v-for="(item,index) in zyList"
                                        :label="item.name"
                                        :value="item.code"
                                        :key="index"
                                      ></option>
                                    </select>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                            <el-col :span="6">
                              <div class="grid-content bg-purple-light div_P">
                                <div class="form-group">
                                  <p>
                                    <label>地址:</label>
                                    <input
                                      type="text"
                                      class="form-control"
                                      disabled
                                      v-model="huizhenObj.Consult_Patient.Address"
                                      placeholder="必填"
                                    >
                                    </input>
                                  </p>
                                </div>
                              </div>
                            </el-col>
                          </el-row>
                        </div>
                      </el-card>

                    </div>
                  </el-tab-pane>
                  <el-tab-pane
                    label="病历摘要"
                    name="third"
                  >
                    <div class="cardP">
                      <el-card class="box-card">
                        <div
                          slot="header"
                          class="clearfix"
                        >
                          <span>病历摘要</span>
                          <el-button
                            style="float: right; padding: 3px 0"
                            type="text"
                            v-if="false"
                          >
                            操作按钮
                          </el-button>
                        </div>
                        <div
                          class="cardC"
                          style="height: 400px;overflow-y: auto"
                        >
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>患者主诉</span>
                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      disabled
                                      placeholder="字数限制200"
                                      maxlength="200"
                                      show-word-limit
                                      v-model="huizhenObj.Consult_Patient_Remark.ZhuSu"
                                    >
                                    </el-input>
                                  </div>

                                </el-card>
                              </div>
                            </el-col>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>现病史</span>

                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      disabled
                                      placeholder="字数限制200"
                                      maxlength="200"
                                      show-word-limit
                                      v-model="huizhenObj.Consult_Patient_Remark.XianBingShi"
                                    >
                                    </el-input>
                                  </div>

                                </el-card>
                              </div>
                            </el-col>

                          </el-row>
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>既往史、个人史、家族史</span>
                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      disabled
                                      placeholder="字数限制1000"
                                      maxlength="1000"
                                      show-word-limit
                                      v-model="huizhenObj.Consult_Patient_Remark.JiWangShi"
                                    >
                                    </el-input>
                                  </div>

                                </el-card>
                              </div>
                            </el-col>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>体格检查</span>

                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      disabled
                                      placeholder="字数限制1000"
                                      maxlength="1000"
                                      show-word-limit
                                      v-model="huizhenObj.Consult_Patient_Remark.TiGeJianCha"
                                    >
                                    </el-input>
                                  </div>

                                </el-card>
                              </div>
                            </el-col>

                          </el-row>
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>辅助检查结果</span>
                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      disabled
                                      placeholder="字数限制1000"
                                      maxlength="1000"
                                      show-word-limit
                                      v-model="huizhenObj.Consult_Patient_Remark.FuZhuJianCha"
                                    >
                                    </el-input>
                                  </div>

                                </el-card>
                              </div>
                            </el-col>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>初步诊断</span>

                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      disabled
                                      placeholder="字数限制1000"
                                      maxlength="1000"
                                      show-word-limit
                                      v-model="huizhenObj.Consult_Patient_Remark.ChuBuZhenDuan"
                                    >
                                    </el-input>
                                  </div>

                                </el-card>
                              </div>
                            </el-col>

                          </el-row>
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>治疗经过</span>
                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      disabled
                                      placeholder="字数限制1000"
                                      maxlength="1000"
                                      show-word-limit
                                      v-model="huizhenObj.Consult_Patient_Remark.ZhiLiaoJingGuo"
                                    >
                                    </el-input>
                                  </div>

                                </el-card>
                              </div>
                            </el-col>
                            <el-col :span="12">

                            </el-col>

                          </el-row>
                        </div>
                      </el-card>
                    </div>
                  </el-tab-pane>
                  <el-tab-pane
                    label="检查检验"
                    name="fourth"
                  >
                    <div class="cardP">
                      <el-card class="box-card">
                        <div
                          slot="header"
                          class="clearfix"
                        >
                          <span>检查检验</span>
                          <el-button
                            style="float: right; padding: 3px 0"
                            type="text"
                            v-if="false"
                          >
                            操作按钮
                          </el-button>
                        </div>
                        <div
                          class="cardC"
                          style="height: 400px;overflow-y: auto"
                        >
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>影像检查</span>
                                    <el-button
                                      type="success"
                                      v-if="false"
                                      style="float: right; padding: 3px 0"
                                      @click="showDialog('JCLB')"
                                    >上传
                                      <i
                                        class="el-icon-upload el-icon--right"></i>
                                    </el-button>
                                  </div>
                                  <div class="fjtable">
                                    <el-table
                                      :data="huizhenObj.Consult_CheckRecords"
                                      height="112"
                                      border
                                      style="width: 100%"
                                    >
                                      <el-table-column
                                        fixed
                                        prop="StudyId"
                                        label="检查号"
                                        width="150"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="CheckTime"
                                        label="检查时间"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="Device"
                                        label="设备名称"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="Modality"
                                        label="检查类型"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="StudyDesc"
                                        label="检查描述"
                                        width="120"
                                      >
                                      </el-table-column>

                                      <el-table-column
                                        fixed="right"
                                        label="操作"
                                        width="100"
                                      >
                                        <template slot-scope="scope">
                                          <el-button
                                            @click="handleClickJCItem(scope.row)"
                                            type="text"
                                            size="small"
                                          >查看
                                          </el-button>
                                          <el-button
                                            type="text"
                                            size="small"
                                            v-if="false"
                                            @click.native.prevent="deleteRow2JC(scope.$index, huizhenObj.Consult_CheckRecords)"
                                          >
                                            删除
                                          </el-button>
                                        </template>
                                      </el-table-column>
                                    </el-table>
                                  </div>
                                </el-card>
                              </div>
                            </el-col>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>病理检查</span>
                                    <el-button
                                      type="success"
                                      v-if="false"
                                      style="float: right; padding: 3px 0"
                                      @click="showDialog('BLLB')"
                                    >上传
                                      <i
                                        class="el-icon-upload el-icon--right"></i>
                                    </el-button>
                                  </div>
                                  <div class="fjtable">
                                    <el-table
                                      :data="huizhenObj.Consult_PathologyRecords"
                                      height="112"
                                      border
                                      style="width: 100%"
                                    >
                                      <el-table-column
                                        fixed
                                        prop="StudyId"
                                        label="检查编号"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        fixed
                                        prop="CheckTime"
                                        label="检查时间"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        fixed
                                        prop="Device"
                                        label="检查设备"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        fixed
                                        prop="Modality"
                                        label="检查类别"
                                        width="120"
                                      >
                                      </el-table-column>

                                      <el-table-column
                                        prop="StudyDesc"
                                        label="检查说明"
                                      >
                                      </el-table-column>

                                      <el-table-column
                                        fixed="right"
                                        label="操作"
                                        width="100"
                                      >
                                        <template slot-scope="scope">
                                          <el-button
                                            @click="handleClickBLItem(scope.row)"
                                            type="text"
                                            size="small"
                                          >查看
                                          </el-button>
                                          <el-button
                                            type="text"
                                            size="small"
                                            v-if="false"
                                            @click.native.prevent="deleteRow2BL(scope.$index, huizhenObj.Consult_PathologyRecords)"
                                          >
                                            删除
                                          </el-button>
                                        </template>
                                      </el-table-column>
                                    </el-table>
                                  </div>
                                </el-card>
                              </div>
                            </el-col>
                          </el-row>
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>检验诊断</span>
                                    <el-button
                                      type="success"
                                      v-if="false"
                                      style="float: right; padding: 3px 0"
                                      @click="showDialog('JYLB')"
                                    >上传
                                      <i
                                        class="el-icon-upload el-icon--right"></i>
                                    </el-button>
                                  </div>
                                  <div class="fjtable">
                                    <el-table
                                      :data="huizhenObj.Consult_TestRecords"
                                      height="112"
                                      border
                                      style="width: 100%"
                                    >
                                      <el-table-column
                                        fixed
                                        prop="TestId"
                                        label="化验单编号"
                                        width="150"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        fixed
                                        prop="ItemName"
                                        label="结果项目名称"
                                        width="150"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="TestTime"
                                        label="化验时间"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="Result"
                                        label="数值"
                                        width="80"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="Unit"
                                        label="单位"
                                        width="80"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="RRS"
                                        label="参考范围"
                                        width="120"
                                      >
                                      </el-table-column>

                                      <el-table-column
                                        fixed="right"
                                        label="操作"
                                        width="100"
                                      >
                                        <template slot-scope="scope">
                                          <el-button
                                            v-if="false"
                                            @click="handleClickJYItem(scope.row)"
                                            type="text"
                                            size="small"
                                          >
                                            查看
                                          </el-button>
                                          <el-button
                                            type="text"
                                            size="small"
                                            v-if="false"
                                            @click.native.prevent="deleteRow2JY(scope.$index, huizhenObj.Consult_TestRecords)"
                                          >
                                            删除
                                          </el-button>
                                        </template>
                                      </el-table-column>
                                    </el-table>
                                  </div>
                                </el-card>
                              </div>
                            </el-col>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>心电检查</span>
                                    <el-button
                                      type="success"
                                      v-if="false"
                                      style="float: right; padding: 3px 0"
                                      @click="showDialog('XDLB')"
                                    >上传
                                      <i
                                        class="el-icon-upload el-icon--right"></i>
                                    </el-button>
                                  </div>
                                  <div class="fjtable">
                                    <el-table
                                      :data="huizhenObj.Consult_ECGRecords"
                                      height="112"
                                      border
                                      style="width: 100%"
                                    >
                                      <el-table-column
                                        fixed
                                        prop="StudyId"
                                        label="检查编号"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        fixed
                                        prop="Device"
                                        label="检查设备"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        fixed
                                        prop="Modality"
                                        label="检查类别"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="CheckTime"
                                        label="检查时间"
                                        width="120"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="StudyDesc"
                                        label="检查说明"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        fixed="right"
                                        label="操作"
                                        width="100"
                                      >
                                        <template slot-scope="scope">
                                          <el-button
                                            @click="handleClickXDItem(scope.row)"
                                            type="text"
                                            size="small"
                                          >查看
                                          </el-button>
                                          <el-button
                                            type="text"
                                            size="small"
                                            v-if="false"
                                            @click.native.prevent="deleteRow2XD(scope.$index, huizhenObj.Consult_ECGRecords)"
                                          >
                                            删除
                                          </el-button>
                                        </template>
                                      </el-table-column>
                                    </el-table>
                                  </div>
                                </el-card>
                              </div>
                            </el-col>
                          </el-row>
                          <el-row>
                            <el-col :span="12">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>相关检查附件</span>
                                    <el-button
                                      type="success"
                                      v-if="false"
                                      style="float: right; padding: 3px 0"
                                    >
                                      上传
                                      <i
                                        class="el-icon-upload el-icon--right"></i>
                                    </el-button>
                                  </div>
                                  <div class="fjtable">
                                    <el-table
                                      :data="huizhenObj.Consult_Files"
                                      height="112"
                                      border
                                      style="width: 100%"
                                    >
                                      <el-table-column
                                        fixed
                                        prop="ConsultId"
                                        label="时间"
                                      >
                                      </el-table-column>
                                      <el-table-column
                                        prop="FilePath"
                                        label="附件名称"
                                      >
                                      </el-table-column>

                                      <el-table-column
                                        fixed="right"
                                        label="操作"
                                        width="100"
                                      >
                                        <template slot-scope="scope">
                                          <el-button
                                            @click="handleClickPICItem(scope.row)"
                                            type="text"
                                            size="small"
                                          >查看
                                          </el-button>
                                          <el-button
                                            type="text"
                                            size="small"
                                            v-if="false"
                                          >删除
                                          </el-button>
                                        </template>
                                      </el-table-column>
                                    </el-table>
                                  </div>

                                </el-card>
                              </div>
                            </el-col>
                            <el-col :span="12">

                            </el-col>

                          </el-row>
                        </div>
                      </el-card>
                    </div>
                  </el-tab-pane>
                  <el-tab-pane
                    label="辅助检查"
                    name="5"
                  >
                    <div class="cardP">
                      <el-card class="box-card">
                        <div
                          slot="header"
                          class="clearfix"
                        >
                          <span>辅助检查</span>
                          <el-button
                            style="float: right; padding: 3px 0"
                            type="text"
                            v-if="false"
                          >
                            操作按钮
                          </el-button>
                        </div>
                        <div
                          class="cardC"
                          style="height: 400px;overflow-y: auto"
                        >
                          <el-row>
                            <el-col :span="24">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>会诊目的</span>
                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      disabled
                                      placeholder="字数限制2000"
                                      maxlength="2000"
                                      show-word-limit
                                      v-model="huizhenObj.Consult.Goal"
                                    >
                                    </el-input>
                                  </div>

                                </el-card>
                              </div>
                            </el-col>
                          </el-row>
                          <el-row>
                            <el-col :span="24">
                              <div class="grid-content bg-purple ">
                                <el-card style="width: 100%">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>补充说明</span>
                                  </div>
                                  <div>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      disabled
                                      placeholder="字数限制1000"
                                      maxlength="1000"
                                      show-word-limit
                                      v-model="huizhenObj.Consult.Describe"
                                    >
                                    </el-input>
                                  </div>
                                </el-card>
                              </div>
                            </el-col>
                          </el-row>

                        </div>
                      </el-card>
                    </div>
                  </el-tab-pane>
                  <el-tab-pane
                    v-if=" huizhenObj.Consult.Status>=4"
                    label="会诊报告"
                    name="6"
                  >
                    <div class="cardP">
                      <el-row>
                        <el-col :span="12">
                          <el-card class="box-card">
                            <div
                              slot="header"
                              class="clearfix"
                            >
                              <span>会诊报告</span>
                              <el-button
                                style="float: right; padding: 3px 0"
                                type="text"
                                v-if="false"
                                @click="finishHZ(4)"
                              >
                                结束会诊
                              </el-button>
                            </div>
                            <div
                              class="cardC"
                              style="height: 400px;overflow-y: auto"
                            >
                              <div
                                v-for="obj in HZBGList"
                                :key="obj"
                                class="text item"
                              >

                                <el-card class="box-card">
                                  <div
                                    slot="header"
                                    class="clearfix"
                                  >
                                    <span>{{obj.ReportUser}}</span>
                                    <el-button
                                      style="float: right; padding: 3px 0"
                                      type="text"
                                      v-if="false"
                                    >删除
                                    </el-button>
                                  </div>
                                  <p>
                                    <span
                                      style="color: #00b3ee;">报告时间：{{obj.ReportTime}}</span>
                                  </p>
                                  <p>
                                    <span>诊断意见：</span>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      disabled
                                      placeholder="字数限制200"
                                      maxlength="200"
                                      show-word-limit
                                      v-model="obj.Diagnosis"
                                    >
                                    </el-input>
                                  </p>
                                  <p>
                                    <span>处理措施：</span>
                                    <el-input
                                      type="textarea"
                                      :rows="4"
                                      disabled
                                      placeholder="字数限制200"
                                      maxlength="200"
                                      show-word-limit
                                      v-model="obj.Treatment"
                                    >
                                    </el-input>
                                  </p>
                                </el-card>
                              </div>
                            </div>
                          </el-card>
                        </el-col>
                        <el-col :span="12">
                          <el-card class="box-card">
                            <div
                              slot="header"
                              class="clearfix"
                            >
                              <span>我的报告</span>
                              <el-button
                                style="float: right; padding: 3px 0"
                                type="text"
                                v-if="huizhenObj.Consult.Status==4"
                                @click="addHZBG()"
                              >
                                提交
                              </el-button>
                            </div>
                            <div
                              class="cardC"
                              style="height: 400px;overflow-y: auto"
                            >
                              <el-row>
                                <el-col :span="24">
                                  <div class="grid-content bg-purple ">
                                    <el-card style="width: 100%">
                                      <div
                                        slot="header"
                                        class="clearfix"
                                      >
                                        <span>诊断意见</span>
                                      </div>
                                      <div>
                                        <el-input
                                          type="textarea"
                                          :rows="4"
                                          placeholder="字数限制200"
                                          maxlength="200"
                                          show-word-limit
                                          v-model="HZBGObj.Diagnosis"
                                        >
                                        </el-input>
                                      </div>
                                    </el-card>
                                  </div>
                                </el-col>
                              </el-row>
                              <el-row>
                                <el-col :span="24">
                                  <div class="grid-content bg-purple ">
                                    <el-card style="width: 100%">
                                      <div
                                        slot="header"
                                        class="clearfix"
                                      >
                                        <span>处理措施</span>
                                      </div>
                                      <div>
                                        <el-input
                                          type="textarea"
                                          :rows="4"
                                          placeholder="字数限制1000"
                                          maxlength="1000"
                                          show-word-limit
                                          v-model="HZBGObj.Treatment"
                                        >
                                        </el-input>
                                      </div>
                                    </el-card>
                                  </div>
                                </el-col>
                              </el-row>

                            </div>
                          </el-card>
                        </el-col>
                      </el-row>
                    </div>
                  </el-tab-pane>
                </el-tabs>
              </el-col>
            </el-row>
            <el-row style="margin-top: 16px">
              <el-col :span="12">
                <el-link disabled></el-link>
              </el-col>
              <el-col :span="12">
                <div class="grid-content bg-purple-light div_P">
                  <!--                                    <el-button type="success" plain v-if="huizhenObj.Consult.Status==3&&isZZ=='OK'" @click="finishHZ(4)">接收</el-button>-->
                  <el-button
                    type="success"
                    plain
                    v-if="huizhenObj.Consult.Status==3"
                    @click="addHZVideo()"
                  >加入会议
                  </el-button>
                  <el-button
                    type="success"
                    plain
                    v-if="isZZ=='OK'&&huizhenObj.Consult.Status==4"
                    @click="finishHZ(5)"
                  >审核
                  </el-button>
                </div>
              </el-col>

            </el-row>
          </div>
        </div>
      </div>

    </div>

    <!--            拍照弹框-->
    <div
      class="blackBg hyCZBg"
      v-if="isShow=='PIC'"
    >
      <div class="panel-default column2">
        <em
          class="closes"
          @click="showDialog('Infor')"
        >×</em>
        <div class="panel-heading">附件详情</div>
        <div class="pucLabel">
          <div class="camera_outer">
            <div class="img_bg_camera">

              <el-image
                style="width: 1100px; height: 460px"
                :src="imgSrcUrl"
                :fit="fill"
              ></el-image>
            </div>
          </div>
        </div>
        <div class="modal-footer">
          <button
            type="button"
            class="btn btn-default"
            @click="showDialog('Infor')"
          >关闭</button>

        </div>
      </div>
    </div>
    <!--弹框选择医生-->
    <div
      class="blackBg hyCZBg"
      v-if="isShowYS=='YSLB'"
    >
      <div class="panel-default column2">
        <em
          class="closes"
          @click="showDialogYS('')"
        >×</em>
        <div class="panel-heading">会诊医生</div>
        <div class="pucLabel">
          <div class="form-group clearfix">
            <p>
              <label>医院：</label>
              <select
                class="form-control"
                v-model="selectZZJGObj"
                @change="getDeptListYS()"
                placeholder="请选择"
              >
                <option
                  v-for="(item,index) in zzjgList"
                  :label="item.HospitalName"
                  :value="item"
                  :key="index"
                ></option>
              </select>
            </p>
            <p>
              <label>科室：</label>
              <select
                class="form-control"
                v-model="selectDeptYS"
                @change="getUserList"
                placeholder="请选择"
              >
                <option
                  v-for="(item,index) in deptListYS"
                  :label="item.Name"
                  :value="item"
                  :key="index"
                ></option>
              </select>
            </p>
          </div>
          <div class="fjtable">
            <el-table
              :data="userList"
              height="112"
              @row-dblclick="selectYSChange"
              border
              style="width: 100%"
            >
              <el-table-column
                fixed
                prop="HospitalId"
                label="所属医院"
              >
              </el-table-column>
              <el-table-column
                prop="name"
                label="科室"
              >
              </el-table-column>
              <el-table-column
                prop="UserName"
                label="姓名"
              >
              </el-table-column>
              <el-table-column
                prop="Title"
                label="擅长"
              >
              </el-table-column>
              <el-table-column
                prop="Describe"
                label="简介"
              >
              </el-table-column>

            </el-table>
          </div>
        </div>
        <div class="modal-footer">
          <button
            type="button"
            class="btn btn-default"
            @click="showDialogYS('')"
          >关闭</button>
        </div>
      </div>
    </div>

    <!--弹框选择检查-->
    <div
      class="blackBg hyCZBg"
      v-if="isShowYS=='JCLB'"
    >
      <div class="panel-default column2">
        <em
          class="closes"
          @click="showDialogYS('')"
        >×</em>
        <div class="panel-heading">上传检查</div>
        <div class="pucLabel">
          <div class="form-group clearfix">
            <p class="selectTime">
              <label style="width: 60px!important;">日期：</label>
              <el-date-picker
                style="width:88px;height:32px"
                type="date"
                v-model="getThreeObj.bdate"
                value-format="yyyy-MM-dd "
                placeholder="选择日期"
              >
              </el-date-picker>
              -
              <el-date-picker
                style="width:88px;height:32px"
                type="date"
                v-model="getThreeObj.edate"
                value-format="yyyy-MM-dd "
                placeholder="选择日期"
              >
              </el-date-picker>
            </p>
            <p>
              <label>患者姓名：</label>
              <input
                type="text"
                class="form-control"
                style="width: 80px!important;"
                v-model="name"
              />
              <button
                type="button"
                @click="getThreeDataList('PACS')"
              >查询</button>
            </p>
          </div>
          <div class="fjtable">
            <el-table
              :data="JCList"
              height="112"
              @row-dblclick="selectJCChange"
              border
              style="width: 100%"
            >
              <el-table-column
                fixed
                prop="StudyId"
                label="检查号"
                width="150"
              >
              </el-table-column>
              <el-table-column
                prop="CheckTime"
                label="检查时间"
                width="120"
              >
              </el-table-column>
              <el-table-column
                prop="Device"
                label="设备名称"
                width="120"
              >
              </el-table-column>
              <el-table-column
                prop="Modality"
                label="检查类型"
                width="120"
              >
              </el-table-column>
              <el-table-column
                prop="StudyDesc"
                label="检查描述"
                width="120"
              >
              </el-table-column>

            </el-table>
          </div>
        </div>
        <div class="modal-footer">
          <button
            type="button"
            class="btn btn-default"
            @click="showDialogYS('')"
          >关闭</button>
          <button
            type="button"
            class="btn btn-primary"
            @click="addJcbw()"
          >保存</button>
        </div>
      </div>
    </div>
    <!--弹框选择病理-->
    <div
      class="blackBg hyCZBg"
      v-if="isShowYS=='BLLB'"
    >
      <div class="panel-default column2">
        <em
          class="closes"
          @click="showDialogYS('')"
        >×</em>
        <div class="panel-heading">上传病理</div>
        <div class="pucLabel">
          <div class="form-group clearfix">
            <p class="selectTime">
              <label style="width: 60px!important;">日期：</label>
              <el-date-picker
                style="width:88px;height:32px"
                type="date"
                v-model="getThreeObj.bdate"
                value-format="yyyy-MM-dd "
                placeholder="选择日期"
              >
              </el-date-picker>
              -
              <el-date-picker
                style="width:88px;height:32px"
                type="date"
                v-model="getThreeObj.edate"
                value-format="yyyy-MM-dd "
                placeholder="选择日期"
              >
              </el-date-picker>
            </p>
            <p>
              <label>患者姓名：</label>
              <input
                type="text"
                class="form-control"
                style="width: 80px!important;"
                v-model="name"
              />
              <button
                type="button"
                @click="getThreeDataList('BL')"
              >查询</button>
            </p>
          </div>
          <div class="fjtable">
            <el-table
              :data="BLList"
              height="112"
              @row-dblclick="selectBLChange"
              border
              style="width: 100%"
            >
              <el-table-column
                fixed
                prop="StudyId"
                label="检查编号"
                width="120"
              >
              </el-table-column>
              <el-table-column
                fixed
                prop="CheckTime"
                label="检查时间"
                width="120"
              >
              </el-table-column>
              <el-table-column
                fixed
                prop="Device"
                label="检查设备"
                width="120"
              >
              </el-table-column>
              <el-table-column
                fixed
                prop="Modality"
                label="检查类别"
                width="120"
              >
              </el-table-column>

              <el-table-column
                prop="StudyDesc"
                label="检查说明"
              >
              </el-table-column>

            </el-table>
          </div>
        </div>
        <div class="modal-footer">
          <button
            type="button"
            class="btn btn-default"
            @click="showDialogYS('')"
          >关闭</button>
          <button
            type="button"
            class="btn btn-primary"
            @click="addJcbw()"
          >保存</button>
        </div>
      </div>
    </div>
    <!--弹框选择检验-->
    <div
      class="blackBg hyCZBg"
      v-if="isShowYS=='JYLB'"
    >
      <div class="panel-default column2">
        <em
          class="closes"
          @click="showDialogYS('')"
        >×</em>
        <div class="panel-heading">上传检验</div>
        <div class="pucLabel">
          <div class="form-group clearfix">
            <p class="selectTime">
              <label style="width: 60px!important;">日期：</label>
              <el-date-picker
                style="width:88px;height:32px"
                type="date"
                v-model="getThreeObj.bdate"
                value-format="yyyy-MM-dd "
                placeholder="选择日期"
              >
              </el-date-picker>
              -
              <el-date-picker
                style="width:88px;height:32px"
                type="date"
                v-model="getThreeObj.edate"
                value-format="yyyy-MM-dd "
                placeholder="选择日期"
              >
              </el-date-picker>
            </p>
            <p>
              <label>患者姓名：</label>
              <input
                type="text"
                class="form-control"
                style="width: 80px!important;"
                v-model="name"
              />
              <button
                type="button"
                @click="getThreeDataList('LIS')"
              >查询</button>
            </p>
          </div>
          <div class="fjtable">
            <el-table
              :data="JYList"
              height="112"
              border
              @row-dblclick="selectJYChange"
              style="width: 100%"
            >
              <el-table-column
                fixed
                prop="TestId"
                label="化验单编号"
                width="150"
              >
              </el-table-column>
              <el-table-column
                fixed
                prop="ItemName"
                label="结果项目名称"
                width="150"
              >
              </el-table-column>
              <el-table-column
                prop="TestTime"
                label="化验时间"
                width="120"
              >
              </el-table-column>
              <el-table-column
                prop="Result"
                label="数值"
                width="80"
              >
              </el-table-column>
              <el-table-column
                prop="Unit"
                label="单位"
                width="80"
              >
              </el-table-column>
              <el-table-column
                prop="RRS"
                label="参考范围"
                width="120"
              >
              </el-table-column>

            </el-table>
          </div>
        </div>
        <div class="modal-footer">
          <button
            type="button"
            class="btn btn-default"
            @click="showDialogYS('')"
          >关闭</button>
          <button
            type="button"
            class="btn btn-primary"
            @click="addJcbw()"
          >保存</button>
        </div>
      </div>
    </div>
    <!--弹框选择心电-->
    <div
      class="blackBg hyCZBg"
      v-if="isShowYS=='XDLB'"
    >
      <div class="panel-default column2">
        <em
          class="closes"
          @click="showDialogYS('')"
        >×</em>
        <div class="panel-heading">上传心电</div>
        <div class="pucLabel">
          <div class="form-group clearfix">
            <p class="selectTime">
              <label style="width: 60px!important;">日期：</label>
              <el-date-picker
                style="width:88px;height:32px"
                type="date"
                v-model="getThreeObj.bdate"
                value-format="yyyy-MM-dd "
                placeholder="选择日期"
              >
              </el-date-picker>
              -
              <el-date-picker
                style="width:88px;height:32px"
                type="date"
                v-model="getThreeObj.edate"
                value-format="yyyy-MM-dd "
                placeholder="选择日期"
              >
              </el-date-picker>
            </p>
            <p>
              <label>患者姓名：</label>
              <input
                type="text"
                class="form-control"
                style="width: 80px!important;"
                v-model="name"
              />
              <button
                type="button"
                @click="getThreeDataList('ECG')"
              >查询</button>
            </p>
          </div>
          <div class="fjtable">
            <el-table
              :data="XDList"
              height="112"
              border
              @row-dblclick="selectXDChange"
              style="width: 100%"
            >
              <el-table-column
                fixed
                prop="StudyId"
                label="检查编号"
                width="120"
              >
              </el-table-column>
              <el-table-column
                fixed
                prop="Device"
                label="检查设备"
                width="120"
              >
              </el-table-column>
              <el-table-column
                fixed
                prop="Modality"
                label="检查类别"
                width="120"
              >
              </el-table-column>
              <el-table-column
                prop="CheckTime"
                label="检查时间"
                width="120"
              >
              </el-table-column>
              <el-table-column
                prop="StudyDesc"
                label="检查说明"
              >
              </el-table-column>

            </el-table>
          </div>
        </div>
        <div class="modal-footer">
          <button
            type="button"
            class="btn btn-default"
            @click="showDialogYS('')"
          >关闭</button>
          <button
            type="button"
            class="btn btn-primary"
            @click="addJcbw()"
          >保存</button>
        </div>
      </div>
    </div>
    <!--            拍照弹框-->
    <div
      class="blackBg hyCZBg"
      v-if="isShowYS=='PZ'"
    >
      <div class="panel-default column2">
        <em
          class="closes"
          @click=" showDialogYS('')"
        >×</em>
        <div class="panel-heading">拍照</div>
        <div class="pucLabel">
          <div class="camera_outer">
            <video
              id="videoCamera"
              :width="videoWidth"
              :height="videoHeight"
              autoplay
            ></video>
            <canvas
              id="canvasCamera"
              :width="videoWidth"
              :height="videoHeight"
            ></canvas>
            <div
              v-if="imgSrc!=''"
              class="img_bg_camera"
            >
              <img
                :src="imgSrc"
                alt=""
                class="tx_img"
              >
            </div>
            <button @click="getCompetence()">打开摄像头</button>
            <button @click="stopNavigator()">关闭摄像头</button>
            <button @click="setImage()">拍照</button>
          </div>
        </div>

        <div class="modal-footer">
          <button
            type="button"
            class="btn btn-default"
            @click="showDialogYS('')"
          >关闭</button>
          <button
            type="button"
            class="btn btn-primary"
            @click="okImage()"
          >保存</button>
        </div>
      </div>
    </div>
  </div>
</template>
<script>
export default {
  name: "Bedinformation",
  data () {
    return {
      msg: "SystemManagement 下的 Bedinformation",
      activeName: 'first',
      radio: '1',
      getHZListObj: {
        topstatus: "1",//菜单级条件(1-我的申请 2-我的会诊)
        secstatus: "1",//二级选项卡条件(1-待办列表 2-已办列表)
        patname: "",//患者姓名
        hospname: "",//申请医院名称
        bdate: "",//申请开始日期
        edate: "",//申请截止日期
        mbdate: "",//会诊开始日期
        medate: "",//会诊截止日期
        ename: "",//会诊专家姓名
        bigtype: "-1",//会诊类型(全部则传-1)
        status: "-1",//会诊状态
        page: "1",//页码,从1开始
        limit: "10",//每页数据量,默认10
      },
      zzjgList: [],
      huizhenList: [],
      total: 1,
      isShow: "",
      isShowYS: "",
      isShowPIC: "",
      inforDisabled: "InFor",
      selectHZInfor: null,
      /*******会诊报告*********/
      //
      HZBGList: [
        {
          Id: 0,
          ConsultId: 0,
          Diagnosis: "会诊诊断1",
          Treatment: "措施1",
          ReportUserId: 0,
          ReportUserName: "张俊华",
          CanWrite: 0,
          ReportTime: "2020-01-16T01:12:20.043Z",
          Status: 0
        },
        {
          Id: 0,
          ConsultId: 0,
          Diagnosis: "会诊诊断2",
          Treatment: "措施2",
          ReportUserId: 0,
          ReportUserName: "王绮红",
          CanWrite: 0,
          ReportTime: "2020-01-16T01:12:20.043Z",
          Status: 0
        },

      ],
      HZBGObj: {
        Id: 0,
        ConsultId: 0,
        Diagnosis: "",
        Treatment: "",
        ReportUserId: 0,
        CanWrite: 0,
        ReportTime: "2020-01-16T01:12:20.043Z",
        Status: 0
      },

      /*****************会诊明细弹框**********************************/
      hzfsList: [
        { name: '普通会诊', code: "1" },
        { name: '专家会诊', code: "2" },
        { name: '知名专家会诊', code: "3" },
        { name: '门诊', code: "4" },
      ],//会诊方式
      jjqkList: [
        { name: '是', code: "1" },
        { name: '否', code: "2" },
      ],//紧急情况
      sqlxList: [
        { name: '普通报告', code: "1" },
        { name: '疑难会诊', code: "2" },
      ],//紧急情况
      sfjhList: [
        { name: '是', code: "1" },
        { name: '否', code: "2" },
      ],//紧急情况
      hzsjList: [
        { name: '上午', code: "1" },
        { name: '下午', code: "2" },
      ],//会诊时间
      //年龄单位
      nldwList: [
        { name: '岁', code: "1" },
        { name: '月', code: "2" },
        { name: '天', code: "3" },
      ],
      //性别
      xbList: [
        { name: '男', code: "1" },
        { name: '女', code: "2" },
        { name: '未知', code: "3" },
      ],
      //婚姻情况
      hyqkList: [
        { name: '未婚', code: "1" },
        { name: '已婚', code: "2" },
        { name: '离异', code: "3" },
      ],
      //患者病情
      hzbqList: [
        { name: '一般', code: "1" },
        { name: '紧急', code: "2" },
        { name: '病危', code: "3" },
      ],
      //医保类别
      yblbList: [
        { name: '自费', code: "1" },
        { name: '居民医保', code: "2" },
        { name: '职工医保', code: "3" },
      ],
      //就诊类型
      jzlxList: [
        { name: '门诊', code: "1" },
        { name: '住院', code: "2" },
      ],
      //国籍
      gjList: [
        { name: '中国', code: "1" },
        { name: '外籍', code: "2" },
      ],
      //民族
      mzList: [
        { name: '汉族', code: "1" },
        { name: '其他少数民族', code: "2" },
      ],
      //职业
      zyList: [
        { name: '自由职业', code: "1" },
        { name: '其他', code: "2" },
      ],
      radio: '1',
      textarea: '',
      isShow: "",
      /********附件详情图片**************/
      imgSrcUrl: "",
      filePICList: [],
      fileList: [],
      /***会诊状态时间轴**/
      activities: [
        {
          content: '申请',
          timestamp: '',
          size: 'large',
          Status: '0',
          type: 'primary',
          icon: '',
          color: ''
        }, {
          Status: '1',
          content: '提交',
          timestamp: '',
          color: '',
          icon: ''
        }, {
          Status: '2',
          content: '前质控',
          timestamp: '',
          size: 'large',
          color: '',
          icon: ''
        }, {
          Status: '3',
          content: '分诊',
          timestamp: '',
          color: '',
          icon: ''
        }, {
          Status: '4',
          content: '报告',
          timestamp: '',
          color: '',
          icon: ''
        }, {
          Status: '5',
          content: '审核',
          timestamp: '',
          color: '',
          icon: ''
        }, {
          Status: '6',
          content: '后质控',
          timestamp: '',
          color: '',
          icon: ''
        }
        , {
          Status: '7',
          content: '完成',
          timestamp: '',
          color: '',
          icon: ''
        }
      ],
      /*************************远程会诊**********************************/
      //会诊实体
      huizhenObj: {
        //会诊对象实体
        Consult: {
          Id: 0,
          HospitalId: 0,
          DeptId: 0,
          DoctorId: 0,
          BigType: 0,
          ConType: 0,
          isEm: 0,
          ReqType: 0,
          isAc: 0,
          SubscribeTime: "2020-01-14T02:09:31.446Z",
          RealSubscribeTime: "2020-01-14T02:09:31.446Z",
          TimeFlag: 0,
          Goal: "",
          Describe: "",
          CreateTime: "2020-01-14T02:09:31.446Z",
          CreateId: 0,
          Status: 0,
          isDeleted: 0
        },
        //患者实体
        Consult_Patient: {
          Id: 0,
          ConsultId: 0,
          Catagory: 0,
          PatientId: 0,
          IDCard: 0,
          Name: "",
          Sex: 0,
          Age: 0,
          AgeUnit: 0,
          Marital: 0,
          Condition: 0,
          Weight: "",
          Height: "",
          BMI: "",
          Country: 0,
          Nation: 0,
          Born: "",
          MedicalCatagory: 0,
          MedicalCard: "",
          TelePhone: "",
          Occupation: "",
          Address: "",
          Dept: "",
          SeekCatagory: 0,
          InDate: "",
          OutDate: ""
        },
        //患者病历摘要
        Consult_Patient_Remark: {
          ConsultId: 0,
          ZhuSu: "",
          XianBingShi: "",
          JiWangShi: "",
          TiGeJianCha: "",
          FuZhuJianCha: "",
          ChuBuZhenDuan: "",
          ZhiLiaoJingGuo: "",
          ZhuanKeBingli: ""
        },
        //会诊医生实体集合
        Consult_Joins: [],
        //化验记录集合
        Consult_TestRecords: [],
        //病理检查记录集合
        Consult_PathologyRecords: [],
        //检查记录集合
        Consult_CheckRecords: [],
        //心电记录集合
        Consult_ECGRecords: [],
        //会诊附件集合
        Consult_Files: []
      },
      //会诊医生实体
      Consult_Join: {
        Id: 0,
        ConsultId: 0,
        DeptKind: 0,
        HospitalId: 0,
        DeptId: 0,
        DoctorId: 0,
        ConRoomId: 0,
        isCanWrite: 0,
        IsMaster: 0,
        joinTime: "2020-01-14T02:09:31.447Z",
        JoinId: 0
      },
      //化验记录实体
      Consult_TestRecord: {
        Id: 0,
        ConsultId: 0,
        PatientId: "string",
        TestId: "string",
        Title: "string",
        TestTime: "string",
        ItemCode: "string",
        ItemName: "string",
        Result: "string",
        Unit: "string",
        RRS: "string",
        ConsultSource: "string"
      },
      //病理检查实体
      Consult_PathologyRecord: {
        Id: 0,
        ConsultId: 0,
        PatientId: "string",
        StudyId: "string",
        Title: "string",
        CheckTime: "string",
        Device: "string",
        Modality: "string",
        StudyDesc: "string",
        ConsultSource: "string"
      },
      //检查记录实体
      Consult_CheckRecord: {
        Id: 0,
        ConsultId: 0,
        PatientId: "string",
        StudyId: "string",
        Title: "string",
        CheckTime: "string",
        Device: "string",
        Modality: "string",
        StudyDesc: "string",
        ConsultSource: "string"
      },
      //心电记录实体
      Consult_ECGRecord: {
        Id: 0,
        ConsultId: 0,
        PatientId: "string",
        StudyId: "string",
        Title: "string",
        CheckTime: "string",
        Device: "string",
        Modality: "string",
        StudyDesc: "string",
        ConsultSource: "string"
      },
      //会诊附件实体
      Consult_File: {
        Id: 0,
        ConsultId: 0,
        Code: "string",
        FilePath: "string",
        ImgType: 0
      },
      /****************************会诊相关字典**********************************/
      zzjgList: [],
      deptList: [],
      selectDept: {},
      LoginInfor: {},
      deptListYS: [],
      selectDeptYS: {},
      selectZZJGObj: {},
      userList: [],
      /**会诊按钮显示**/
      isZZ: "",
      JCList: [],
      BLList: [],
      JYList: [],
      XDList: [],
      getThreeObj: {
        kind: "",//数据类别(PACS-检查 BL-病理 ECG-心电图 LIS-化验 US-超声检查)
        bdate: "",
        edate: "",
        patname: "",
      },
    };
  },
  methods: {
    setInforSture (type) {
      for (var i = 0; i < this.activities.length; i++) {
        if (this.activities[i].Status < type) {
          this.activities[i].icon = 'el-icon-more';
          this.activities[i].type = 'primary';
          this.activities[i].color = '';
        } else if (this.activities[i].Status == type) {
          this.activities[i].icon = '';
          this.activities[i].type = '';
          this.activities[i].color = '#0bbd87';
        } else {
          this.activities[i].icon = '';
          this.activities[i].type = '';
          this.activities[i].color = '';
        }

      }
    },
    showDialog (show) {
      this.isShow = show;
      if (show == "") {
        this.selectHZInfor = null
      }

    },
    showDialogYS (show) {
      this.isShowYS = show;
    },
    handleClickInforItem (row) {
      console.log("查看详情操作");
      console.log(row);
      this.getHZInfor(row.Id)
      this.selectHZInfor = row;
      this.getHZBGList();
    },
    handleClick (tab, event) {
      console.log(tab, event);
      this.getHZList();
    },
    handleCurrentChange (val) {
      console.log(`当前页: ${val}`);
      this.getHZListObj.page = val;
      this.getHZList()
    },
    getHZList () {
      this.huizhenList = [];
      var params = this.getHZListObj;
      this.$get("ConsultBuss/GetList", params)
        .then(res => {
          console.log("会诊列表查询结果");
          console.log(res);
          this.total = res.data.TotalCount;
          this.huizhenList = res.data.list[0].Table;
          for (var i = 0; i < this.huizhenList.length; i++) {
            if (this.huizhenList[i].Status == 0) {
              this.huizhenList[i].StatusName = '申请'
            } else if (this.huizhenList[i].Status == 1) {
              this.huizhenList[i].StatusName = '提交'
            } else if (this.huizhenList[i].Status == 2) {
              this.huizhenList[i].StatusName = '前质控'
            } else if (this.huizhenList[i].Status == 3) {
              this.huizhenList[i].StatusName = '分诊'
            } else if (this.huizhenList[i].Status == 4) {
              this.huizhenList[i].StatusName = '报告'
            } else if (this.huizhenList[i].Status == 5) {
              this.huizhenList[i].StatusName = '审核'
            } else if (this.huizhenList[i].Status == 6) {
              this.huizhenList[i].StatusName = '后质控'
            } else if (this.huizhenList[i].Status == 7) {
              this.huizhenList[i].StatusName = '完成'
            }

          }
        })
        .catch(err => {
          console.log(err);
        });
    },
    getHZInfor (ConsultId) {

      var params = {
        ConsultId: ConsultId
      };
      this.$get("ConsultBuss/Get", params)
        .then(res => {
          console.log("会诊明细查询结果");
          console.log(res);
          if (res.code == 0) {
            this.huizhenObj = res.data;

            for (var i = 0; i < this.huizhenObj.Consult_Files.length; i++) {
              this.huizhenObj.Consult_Files[i].picPth = this.$getBaseIP() + this.huizhenObj.Consult_Files[i].FilePath
              this.huizhenObj.Consult_Files[i].type = 1;
              this.filePICList.push(this.huizhenObj.Consult_Files[i]);
            }
            console.log("会诊状态")
            console.log(this.getHZListObj.topstatus)
            console.log(this.huizhenObj.Consult.Status)
            this.setInforSture(this.huizhenObj.Consult.Status);
            if (this.huizhenObj.Consult.Status == 0 && this.getHZListObj.topstatus == 1) {
              this.showDialog('InforUpdate')
            } else {
              this.showDialog('Infor')
              console.log(this.LoginInfor.UserId);
              for (var i = 0; i < this.huizhenObj.Consult_Joins.length; i++) {
                console.log(this.huizhenObj.Consult_Joins[i].DoctorId)
                console.log(this.huizhenObj.Consult_Joins[i].IsMaster)
                if (this.huizhenObj.Consult_Joins[i].DoctorId == this.LoginInfor.UserId && this.huizhenObj.Consult_Joins[i].IsMaster == 1) {
                  this.isZZ = "OK"
                  console.log("主诊本登录账号")
                }
              }
            }

          }

        })
        .catch(err => {
          console.log(err);
        });
    },
    addHZBG () {
      if (this.selectHZInfor == null) {
        this.$message({
          showClose: true,
          message: "请选择会诊明细！",
          type: "error"
        });
        return;
      }
      this.HZBGObj.ConsultId = this.selectHZInfor.Id;
      this.HZBGObj.ReportUserId = this.LoginInfor.UserId;
      var params = this.HZBGObj;
      //POST /api/ConsultReport/Create
      this.$post("ConsultReport/Create", params)
        .then(res => {
          console.log("添加会诊报告结果");
          console.log(res);
          if (res.code == 0) {
            this.getHZBGList();
            // if (this.isZZ == 'OK') {
            //     // this.finishHZ(4);
            //     this.finishHZ(5);
            // }
          } else {
            this.$message({
              showClose: true,
              message: "会诊报告添加失败！",
              type: "error"
            });
          }
        })
        .catch(err => {
          console.log(err);
        });
    },
    getHZBGList () {
      this.HZBGList = [];
      if (this.selectHZInfor == null) {
        this.$message({
          showClose: true,
          message: "请选择会诊明细！",
          type: "error"
        });
        return;
      }
      var params = {
        ConsultId: this.selectHZInfor.Id
      };
      this.$get("ConsultReport/GetList", params)
        .then(res => {
          console.log("会诊报告列表查询结果");
          console.log(res);
          this.HZBGList = res.data;
        })
        .catch(err => {
          console.log(err);
        });
    },
    finishHZ (Status) {
      if (this.selectHZInfor == null) {
        this.$message({
          showClose: true,
          message: "请选择会诊数据！",
          type: "error"
        });
        return;
      }
      var params = {
        ConsultId: this.selectHZInfor.Id,
        Status: Status
      };
      //POST /api/ConsultBuss/ChangeConsultStatus
      this.$post("ConsultBuss/ChangeConsultStatus", params)
        .then(res => {
          console.log("结束会诊结果");
          console.log(res);
          if (res.code == 0) {
            this.getHZList();
            this.getHZInfor(this.selectHZInfor.Id);
            if (Status == 1) {
              this.showDialog('')
              this.getHZInfor(this.selectHZInfor.Id)
            }
            if (Status == 5) {
              this.showDialog('')
            }
          } else {
            this.$message({
              showClose: true,
              message: res.msg,
              type: "error"
            });
          }
        })
        .catch(err => {
          console.log(err);
        });
    },
    handleClickPICItem (row) {
      console.log(row);
      this.imgSrcUrl = this.$getBaseIP() + row.FilePath;
      console.log("图片路径")
      console.log(this.imgSrcUrl)
      this.showDialog("PIC");
    },
    addHZVideo () {
      if (this.isZZ == 'OK') {
        console.log("加入会议执行更改状态操作")
        this.finishHZ(4);
      }
      if (this.selectHZInfor == null) {
        this.$message({
          showClose: true,
          message: "请选择会诊明细！",
          type: "error"
        });
        return;
      }
      var params = {
        ConsultId: this.selectHZInfor.Id
      };
      this.$get("ConsultBuss/GetVideoUrl", params)
        .then(res => {
          console.log("会诊视频地址查询结果");
          console.log(res);
          // this.LoginInfor.UserName = "张珊"
          // var roomUrl = "https://121.43.170.162/webapp/conference/663800?name=" + this.LoginInfor.UserName + "&role=host"
          if (res.code == 0) {
            console.log("执行加入会议跳转")
            window.open(res.data, "_blank");
          }

        })
        .catch(err => {
          console.log(err);
        });


    },
    /******************获取医生*************************/
    getZZJGList () {
      this.zzjgList = [];
      var params = {
        name: ""
      };
      this.$get("Hospital/GetList", params)
        .then(res => {
          //this.total = res.data.totalCount;//
          this.zzjgList = res.data;
          if (this.zzjgList.length > 0) {
            this.selectZZJGObj = this.zzjgList[0];
            this.getDeptListYS();
          }
          console.log("组织机构列表查询结果");
          console.log(res);
        })
        .catch(err => {
          console.log(err);
        });
    },
    getDeptListYS () {
      //
      var params = {
        HospitalId: this.selectZZJGObj.HospitalId,
        name: ""
      };
      this.$get("Dept/GetList", params)
        .then(res => {
          this.deptListYS = res.data;
          console.log("科室列表查询结果");
          console.log(res);
        })
        .catch(err => {
          console.log(err);
        });
    },
    getUserList () {
      this.userList = [];

      if (this.selectZZJGObj == null) {
        this.$message({
          showClose: true,
          message: "请选择操作机构！",
          type: "error"
        });
        return;
      }
      var params = {
        HospitalId: this.selectZZJGObj.HospitalId,
        SectionId: this.selectDeptYS.Id
      };
      this.$get("User/GetListBySection", params)
        .then(res => {
          this.userList = res.data;
          console.log("用户列表查询结果");
          console.log(res);
        })
        .catch(err => {
          console.log(err);
        });
    },
    /**选择医生弹框*/
    selectYSChange (val, column, event) {
      console.log("选中会诊医生数据");
      console.log(val)
      var Consult_Join = {
        Id: -1,
        ConsultId: -1,
        DeptKind: 0,
        HospitalId: val.HospitalId,
        DeptId: this.selectDeptYS.Id,
        DoctorId: val.UserId,
        Doctor: val.UserName,
        UserName: val.UserName,
        Title: val.Title,
        Describe: val.Describe,
        ConRoomId: -1,
        isCanWrite: 0,
        IsMaster: 0,
        joinTime: "2020-01-14T02:09:31.447Z",
        JoinId: 0
      }
      this.huizhenObj.Consult_Joins.push(Consult_Join)
      this.showDialogYS('')
    },
    handleClickYSItem (row) {
      console.log("查看医生操作");
      console.log(row);
    },
    updateRow2YS (index, rows) {
      console.log("是否主诊");
      console.log(index);
      var rowItem = rows[index];
      rows.forEach(m => {
        if (m.DoctorId == rowItem.DoctorId) {
          if (m.IsMaster == 0) {
            m.IsMaster = 1;
          } else {
            m.IsMaster = 0;
          }
        } else {
          m.IsMaster = 0;
        }
      })
    },
    deleteRow2YS (index, rows) {
      console.log("删除医生操作");
      console.log(index);
      rows.splice(index, 1);
    },
    /***选择第三方检查￥￥￥￥￥￥￥￥￥￥￥￥￥￥￥￥￥￥￥￥￥￥￥*/
    selectJCChange (val, column, event) {
      console.log("选中检查数据");
      console.log(val)
      this.huizhenObj.Consult_CheckRecords.push(val)
      this.showDialogYS('')
    },

    deleteRow2JC (index, rows) {
      console.log("删除检查操作");
      console.log(index);
      rows.splice(index, 1);
    },
    //病理检查
    selectBLChange (val, column, event) {
      console.log("选中病理数据");
      console.log(val)
      this.huizhenObj.Consult_PathologyRecords.push(val)
      this.showDialogYS('')
    },

    deleteRow2BL (index, rows) {
      console.log("删除病理操作");
      console.log(index);
      rows.splice(index, 1);
    },
    //检验结果
    selectJYChange (val, column, event) {
      console.log("选中检验数据");
      console.log(val)
      this.huizhenObj.Consult_TestRecords.push(val)
      this.showDialogYS('')
    },
    handleClickJYItem (row) {
      console.log("查看检验操作");
      console.log(row);
    },
    deleteRow2JY (index, rows) {
      console.log("删除检验操作");
      console.log(index);
      rows.splice(index, 1);
    },
    //心电结果
    selectXDChange (val, column, event) {
      console.log("选中心电数据");
      console.log(val)
      this.huizhenObj.Consult_ECGRecords.push(val)
      this.showDialogYS('')
    },

    deleteRow2XD (index, rows) {
      console.log("删除心电操作");
      console.log(index);
      rows.splice(index, 1);
    },

    /***********获取第三方检查检验数据**************/
    getThreeDataList (kind) {
      this.JCList = [];
      this.BLList = [];
      this.JYList = [];
      this.XDList = [];
      this.getThreeObj.kind = kind;
      var params = {
        kind: this.getThreeObj.kind,
        bdate: this.getThreeObj.bdate,
        edate: this.getThreeObj.edate,
        patname: this.getThreeObj.patname,
      };
      //GET /api/ThreeDataBuss/GetList
      this.$get("ThreeDataBuss/GetList", params)
        .then(res => {
          console.log("检查检验查询结果");
          console.log(res);
          if (res.data != null && res.data.length > 0) {
            console.log("检查检验")
            console.log(res.data[0].Table);
            if (kind == "PACS") {//数据类别(PACS-检查 BL-病理 ECG-心电图 LIS-化验 US-超声检查)
              this.JCList = res.data[0].Table;
            } else if (kind == "BL") {
              this.BLList = res.data[0].Table;
            } else if (kind == "LIS") {
              this.JYList = res.data[0].Table;
            } else if (kind == "ECG") {
              this.XDList = res.data[0].Table;
            }
          }

        })
        .catch(err => {
          console.log(err);
        });
    },
    /*****************************会诊详情框*******************************************************/
    handleClickJCItem (row) {
      console.log("查看检查操作");
      console.log(row);
      this.$scanOpenJC("PACS", row.StudyId, this.getMsg)
    },
    handleClickBLItem (row) {
      console.log("查看病理操作");
      console.log(row);
      this.$scanOpenJC("US", row.StudyId, this.getMsg)
    },
    handleClickXDItem (row) {
      console.log("查看心电操作");
      console.log(row);
      this.$scanOpenJC("ECG", row.StudyId, this.getMsg)
    },
    /*******************************保存会诊********************************************/
    addHZObj () {
      // this.uploadFiles();
      // setTimeout(() => {
      //     this.addHZObj2()
      // }, 1000);
    },
    addHZObj2 () {
      for (var i = 0; i < this.filePICList.length; i++) {
        if (this.filePICList[i].type != 1) {
          this.filePICList[i].FilePath = this.filePICList[i].FilePath.toString().substr(this.filePICList[i].FilePath.toString().indexOf(',') + 1);
        }

      }
      this.huizhenObj.Consult_Files = this.filePICList;

      var params = this.huizhenObj;
      console.log("添加会诊实体");
      console.log(params);
      //POST /api/ConsultBuss/Update
      this.$post("ConsultBuss/Update", params)
        .then(res => {
          console.log("添加会诊结果");
          console.log(res);
          if (res.code == 0) {
            this.selectDeptYS = {};
            this.selectZZJGObj = {};
            this.huizhenObj = {
              //会诊对象实体
              Consult: {
                Id: 0,
                HospitalId: 0,
                DeptId: 0,
                DoctorId: 0,
                BigType: 0,
                ConType: 0,
                isEm: 0,
                ReqType: 0,
                isAc: 0,
                SubscribeTime: "2020-01-14T02:09:31.446Z",
                RealSubscribeTime: "2020-01-14T02:09:31.446Z",
                TimeFlag: 0,
                Goal: "",
                Describe: "",
                CreateTime: "2020-01-14T02:09:31.446Z",
                CreateId: 0,
                Status: 0,
                isDeleted: 0
              },
              //患者实体
              Consult_Patient: {
                Id: 0,
                ConsultId: 0,
                Catagory: 0,
                PatientId: 0,
                IDCard: 0,
                Name: "",
                Sex: 0,
                Age: 0,
                AgeUnit: 0,
                Marital: 0,
                Condition: 0,
                Weight: "",
                Height: "",
                BMI: "",
                Country: 0,
                Nation: 0,
                Born: "",
                MedicalCatagory: 0,
                MedicalCard: "",
                TelePhone: "",
                Occupation: "",
                Address: "",
                Dept: "",
                SeekCatagory: 0,
                InDate: "",
                OutDate: ""
              },
              //患者病历摘要
              Consult_Patient_Remark: {
                ConsultId: 0,
                ZhuSu: "",
                XianBingShi: "",
                JiWangShi: "",
                TiGeJianCha: "",
                FuZhuJianCha: "",
                ChuBuZhenDuan: "",
                ZhiLiaoJingGuo: "",
                ZhuanKeBingli: ""
              },
              //会诊医生实体集合
              Consult_Joins: [],
              //化验记录集合
              Consult_TestRecords: [],
              //病理检查记录集合
              Consult_PathologyRecords: [],
              //检查记录集合
              Consult_CheckRecords: [],
              //心电记录集合
              Consult_ECGRecords: [],
              //会诊附件集合
              Consult_Files: []
            };
            this.finishHZ(1)
          } else {
            this.$message({
              showClose: true,
              message: "会诊创建失败！",
              type: "error"
            });
          }
        })
        .catch(err => {
          console.log(err);
        });

    },
    /*****************附件上传*******************/
    changeUpload (file, fileList) {
      console.log("选择照片改变时")
      console.log(file)
      console.log(fileList)
      var That = this;
      var imgFile;
      var reader = new FileReader();     //html5读文件
      reader.readAsDataURL(file.raw); //转BASE64
      reader.onload = function (e) {        //读取完毕后调用接口
        imgFile = e.target.result;
        console.log("Base64图片：");
        console.log(imgFile);
        var Consult_File = {
          Id: 0,
          ConsultId: 0,
          Code: "string",
          FilePath: imgFile,
          picPth: imgFile,
          ImgType: 0
        }
        That.filePICList.push(Consult_File);
      };
    },
    deleteRowPIC (index, rows) {
      rows.splice(index, 1);
    },
    /**********************************拍照****************************/
    // 调用权限（打开摄像头功能）
    getCompetence () {
      var _this = this
      this.thisCancas = document.getElementById('canvasCamera')
      this.thisContext = this.thisCancas.getContext('2d')
      this.thisVideo = document.getElementById('videoCamera')
      // 旧版本浏览器可能根本不支持mediaDevices，我们首先设置一个空对象
      if (navigator.mediaDevices === undefined) {
        navigator.mediaDevices = {}
      }
      // 一些浏览器实现了部分mediaDevices，我们不能只分配一个对象
      // 使用getUserMedia，因为它会覆盖现有的属性。
      // 这里，如果缺少getUserMedia属性，就添加它。
      if (navigator.mediaDevices.getUserMedia === undefined) {
        navigator.mediaDevices.getUserMedia = function (constraints) {
          // 首先获取现存的getUserMedia(如果存在)
          var getUserMedia = navigator.webkitGetUserMedia || navigator.mozGetUserMedia || navigator.getUserMedia
          // 有些浏览器不支持，会返回错误信息
          // 保持接口一致
          if (!getUserMedia) {
            return Promise.reject(new Error('getUserMedia is not implemented in this browser'))
          }
          // 否则，使用Promise将调用包装到旧的navigator.getUserMedia
          return new Promise(function (resolve, reject) {
            getUserMedia.call(navigator, constraints, resolve, reject)
          })
        }
      }
      var constraints = {
        audio: false,
        video: { width: this.videoWidth, height: this.videoHeight, transform: 'scaleX(-1)' }
      }
      navigator.mediaDevices.getUserMedia(constraints).then(function (stream) {
        // 旧的浏览器可能没有srcObject
        if ('srcObject' in _this.thisVideo) {
          _this.thisVideo.srcObject = stream
        } else {
          // 避免在新的浏览器中使用它，因为它正在被弃用。
          _this.thisVideo.src = window.URL.createObjectURL(stream)
        }
        _this.thisVideo.onloadedmetadata = function (e) {
          _this.thisVideo.play()
        }
      }).catch(err => {
        console.log(err)
      })
    },
    //  绘制图片（拍照功能）
    setImage () {
      var _this = this
      // 点击，canvas画图
      _this.thisContext.drawImage(_this.thisVideo, 0, 0, _this.videoWidth, _this.videoHeight)
      // 获取图片base64链接
      var image = this.thisCancas.toDataURL('image/png')
      _this.imgSrc = image
      this.$emit('refreshDataList', this.imgSrc)
      this.stopNavigator();
    },
    okImage () {
      console.log("拍照图片Base64")
      console.log(this.imgSrc);
      var filePIC = this.dataURLtoFile(this.imgSrc, "123");
      console.log("图片文件")
      console.log(filePIC);
      var Consult_File = {
        Id: 0,
        ConsultId: 0,
        Code: "string",
        FilePath: this.imgSrc,
        picPth: this.imgSrc,
        ImgType: 0
      }
      this.filePICList.push(Consult_File);

      this.imgSrc = "";
      this.showDialog('')
      // this.getCompetence();
    },
    // base64转文件
    dataURLtoFile (dataurl, filename) {
      var arr = dataurl.split(',')
      var mime = arr[0].match(/:(.*?);/)[1]
      var bstr = atob(arr[1])
      var n = bstr.length
      var u8arr = new Uint8Array(n)
      while (n--) {
        u8arr[n] = bstr.charCodeAt(n)
      }
      return new File([u8arr], filename, { type: mime })
    },
    // 关闭摄像头
    stopNavigator () {
      this.thisVideo.srcObject.getTracks()[0].stop()
    }

  },
  created () {
    if (this.$route.query.Token) {
      localStorage.setItem('Token', this.$route.query.Token)
    }
    this.getZZJGList();
    this.getHZList();
  }
};
</script>
<style lang="scss">
.Bedinformation1 {
  .selectTime {
    .el-input__icon {
      height: 100%;
      width: 25px;
      display: none;
      text-align: center;
      -webkit-transition: all 0.3s;
      transition: all 0.3s;
      line-height: 40px;
    }

    .input {
      width: 90px !important;
      height: 28px !important;
    }
  }

  .selectPic {
    ul {
      padding: 0;
      display: none;
    }
  }

  .column2 {
    width: 128rem;
    margin: -38px auto !important;
    overflow-y: auto !important;
    background: #fff;
    border-radius: 5px;
    position: relative;
  }

  .div_P {
    .form-control {
      display: inline-block;
      width: 180px;
      height: 32px;
      padding: 5px 12px;
      font-size: 14px;
      line-height: 1.42857143;
      color: #555;
      background-color: #fff;
      background-image: none;
      border: 1px solid #ccc;
      border-radius: 4px;
      -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
      box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
      -webkit-transition: border-color ease-in-out 0.15s,
        -webkit-box-shadow ease-in-out 0.15s;
      transition: border-color ease-in-out 0.15s,
        -webkit-box-shadow ease-in-out 0.15s;
      transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;
      transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s,
        -webkit-box-shadow ease-in-out 0.15s;
    }

    .form-group {
      height: 45px;
      margin: 0;
      line-height: 32px;
      padding: 6px 15px 0 15px;
    }
  }

  .fjtable {
    .el-table {
      font-size: 10px !important;
    }
  }

  .cardP {
    .text {
      font-size: 14px;
    }

    .el-card__header {
      padding: 18px 20px;
      border-bottom: 1px solid #ebeef5;
      -webkit-box-sizing: border-box;
      box-sizing: border-box;
      background-color: azure;
    }

    .item {
      margin-bottom: 18px;
    }

    .clearfix:before,
    .clearfix:after {
      display: table;
      content: "";
    }

    .clearfix:after {
      clear: both;
    }

    .box-card {
      width: 100%;
    }
  }

  .cardC {
    .text {
      font-size: 14px;
    }

    .el-card__header {
      padding: 10px 20px;
      border-bottom: 1px solid #ebeef5;
      -webkit-box-sizing: border-box;
      box-sizing: border-box;
      background-color: white;
    }

    .el-card__body {
      padding: 8px;
    }

    .item {
      margin-bottom: 18px;
    }

    .clearfix:before,
    .clearfix:after {
      display: table;
      content: "";
    }

    .clearfix:after {
      clear: both;
    }

    .box-card {
      width: 100%;
    }
  }

  .el-tree-node.is-current > .el-tree-node__content {
    color: #fff;
    background: #155a00 !important;
  }

  .dRightMain {
    padding: 18px;
  }

  .custom-tree-node {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 14px;
    padding-right: 8px;
  }

  .el-table {
    font-size: 14px !important;
  }

  .el-table thead {
    color: #303133;
  }

  .dRightMain .Tb {
    position: absolute;
    top: 91px;
    left: 240px;
    right: 15px;
    bottom: 0;
    border: 1px solid #ddd;
  }
}

.InspectionCL22 {
  .selectTime {
    .el-input__icon {
      height: 100%;
      width: 25px;
      display: none;
      text-align: center;
      -webkit-transition: all 0.3s;
      transition: all 0.3s;
      line-height: 40px;
    }

    .input {
      width: 90px !important;
      height: 28px !important;
    }
  }

  .form-control {
    width: 106px !important;
  }

  .div_P {
    .form-control {
      display: inline-block;
      width: 180px;
      height: 32px;
      padding: 5px 12px;
      font-size: 14px;
      line-height: 1.42857143;
      color: #555;
      background-color: #fff;
      background-image: none;
      border: 1px solid #ccc;
      border-radius: 4px;
      -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
      box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
      -webkit-transition: border-color ease-in-out 0.15s,
        -webkit-box-shadow ease-in-out 0.15s;
      transition: border-color ease-in-out 0.15s,
        -webkit-box-shadow ease-in-out 0.15s;
      transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;
      transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s,
        -webkit-box-shadow ease-in-out 0.15s;
    }

    .form-group {
      height: 45px;
      margin: 0;
      line-height: 32px;
      padding: 6px 15px 0 15px;
    }
  }

  .fjtable {
    .el-table {
      font-size: 10px !important;
    }
  }

  .cardP {
    .text {
      font-size: 14px;
    }

    .el-card__header {
      padding: 18px 20px;
      border-bottom: 1px solid #ebeef5;
      -webkit-box-sizing: border-box;
      box-sizing: border-box;
      background-color: azure;
    }

    .item {
      margin-bottom: 18px;
    }

    .clearfix:before,
    .clearfix:after {
      display: table;
      content: "";
    }

    .clearfix:after {
      clear: both;
    }

    .box-card {
      width: 100%;
    }
  }

  .cardC {
    .text {
      font-size: 14px;
    }

    .el-card__header {
      padding: 10px 20px;
      border-bottom: 1px solid #ebeef5;
      -webkit-box-sizing: border-box;
      box-sizing: border-box;
      background-color: white;
    }

    .el-card__body {
      padding: 8px;
    }

    .item {
      margin-bottom: 18px;
    }

    .clearfix:before,
    .clearfix:after {
      display: table;
      content: "";
    }

    .clearfix:after {
      clear: both;
    }

    .box-card {
      width: 100%;
    }
  }

  .el-tree-node.is-current > .el-tree-node__content {
    color: #fff;
    background: #155a00 !important;
  }

  .dRightMain {
    padding: 18px;
  }

  .custom-tree-node {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 14px;
    padding-right: 8px;
  }

  .el-table {
    font-size: 14px !important;
  }

  .el-table thead {
    color: #303133;
  }

  .dRightMain .Tb {
    position: absolute;
    top: 91px;
    left: 240px;
    right: 15px;
    bottom: 0;
    border: 1px solid #ddd;
  }
}
</style>
